Re: have problems with div's

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



>> > You need to set up your forms so that when a user makes a selection or
>> > changes a selection
>> > it always fires the javascript
>> > Each time the script fires, it will then rewrite those items to the
>> > table.

the script would be called from (table1) the script would then rewrite the
array contents a fresh in (table2). how could it do this.? what script in
table1 would clear the contents of a table2 to allow me to rewrite them.?
both tables are within the same internet explorer window.



"Steve Easton" <admin@xxxxxxxxxxxxx> wrote in message
news:e7nXRFAXFHA.136@xxxxxxxxxxxxxxxxxxxxxxx
> You don't access the array from the frame, you access the array via a
> function. You fire the
> function with a mouse or keyboard event.
>
> --
> Steve Easton
> Microsoft MVP FrontPage
> 95isalive
> This site is best viewed............
> .......................with a computer
>
> <cheers> wrote in message news:O3JYcl$WFHA.1404@xxxxxxxxxxxxxxxxxxxxxxx
>> ok, think i can do this another way using an array.
>>
>> can i access an array from different frames?
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> "Steve Easton" <admin@xxxxxxxxxxxxx> wrote in message
>> news:uuQDYh7WFHA.1508@xxxxxxxxxxxxxxxxxxxxxxx
>> > You need to set up your forms so that when a user makes a selection or
>> > changes a selection
>> > it always fires the javascript
>> > Each time the script fires, it will then rewrite those items to the
>> > table.
>> >
>> >
>> > --
>> > Steve Easton
>> > Microsoft MVP FrontPage
>> > 95isalive
>> > This site is best viewed..................
>> > ..............................with a computer
>> >> the above did not work. i do not understand how the script can be
>> >> written
>> >> correctly, it would only run once as it is witin a HTML file. or have
>> >> i
>> >> got
>> >> to create a .js file and have a call to it to keep executing it.
>> >>
>> >> just a thought. is there a way to get lets say iframe (id "I1") to
>> >> document.write(....) to id "table6"
>> >> where the document.write(...) lines are in the iframe id I1 but
>> >> it
>> >> prints to id "table6"
>> >> html file below to show what i mean by this.
>> >>
>> >> yes the tables are empty, just wanted to show the table layout, so you
>> >> know
>> >> what i mean by from one table to another.
>> >>
>> >> thank you.
>> >>
>> >>
>> >>
>> >>
>> >> <html>
>> >>
>> >> <head>
>> >> <title>New Page 1</title>
>> >> </head>
>> >> <body>
>> >> <table border="0" cellpadding="0" style="border-collapse: collapse"
>> >> width="1092" id="table3" height="633">
>> >> <tr>
>> >> <td align="left" valign="top" width="159">
>> >> <table border="0" cellpadding="0" style="border-collapse: collapse"
>> >> width="153" id="table4" height="43">
>> >> <tr>
>> >> <td valign="top">
>> >> <table border="0" cellpadding="0" style="border-collapse: collapse"
>> >> width="150" id="table5">
>> >> <tr>
>> >> <td colspan="2">
>> >> <p align="center">Total Cost of your order</p>
>> >> </td>
>> >> </tr>
>> >> <tr>
>> >> <td width="28">
>> >> <p align="right">£</td>
>> >> <td width="122"><div id="theTotal"></div></td>
>> >> </tr>
>> >> </table>
>> >> </td>
>> >> </tr>
>> >> </table>
>> >> <table border="0" cellpadding="0" style="border-collapse: collapse"
>> >> width="152" id="table6" height="475">
>> >> <tr>
>> >> <td valign="top">
>> >> =====
>> >> .......
>> >> </td>
>> >> </tr>
>> >> </table>
>> >> </td>
>> >> <td align="left" valign="top">
>> >> <iframe name="I1" width="912" height="623" align="top"
>> >> target="_blank"
>> >> src="new_page_2.htm">
>> >> Your browser does not support inline frames or is currently
>> >> configured
>> >> not
>> >> to display inline frames.
>> >> </iframe></td>
>> >> </tr>
>> >> </table>
>> >> </body>
>> >> </html>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> "Murray" <forums@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> >> news:eyC2u%23zWFHA.160@xxxxxxxxxxxxxxxxxxxxxxx
>> >> > No - he means use js to write the HTML to the page after testing to
>> >> > see
>> >> > if
>> >> > there is content. For example -
>> >> >
>> >> > <script type="text/javascript">
>> >> > //here begins javascript written by a non-javascripter
>> >> > //consider it poorly written pseudo-code
>> >> >
>> >> > if div bAvocado content != "" {
>> >> > document.write("<div id='bAvocado'>" + AvocadoContent + "</" +
>> >> > "div>")
>> >> > and so on....
>> >> > </script>
>> >> > --
>> >> > Murray
>> >> > ============
>> >> >
>> >> > <cheers> wrote in message
>> >> > news:uyYqmJzWFHA.2572@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >> not really sure what you mean by on the fly ?
>> >> >>
>> >> >> enclose them in a <script> .... </script>
>> >> >>
>> >> >> <script language="javascript">
>> >> >> <div id="bAvocado"></div>
>> >> >> <div id="bButterSquash"></div>
>> >> >> <div id="bCauliflower"></div>
>> >> >> <div id="bCornOnCob"></div>
>> >> >> <div id="bCucumber"></div>
>> >> >> <div id="bGarlic"></div>
>> >> >> </script>
>> >> >>
>> >> >>
>> >> >>
>> >> >> "Steve Easton" <admin@xxxxxxxxxxxxx> wrote in message
>> >> >> news:u5NvQ6yWFHA.2288@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>> Write the div tags on the fly using javascript
>> >> >>>
>> >> >>> --
>> >> >>> Steve Easton
>> >> >>> Microsoft MVP FrontPage
>> >> >>> 95isalive
>> >> >>> This site is best viewed............
>> >> >>> .......................with a computer
>> >> >>>
>> >> >>> <cheers> wrote in message
>> >> >>> news:OnGr5gyWFHA.3584@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> ok
>> >> >>>>
>> >> >>>> lets say that the following are set using the command
>> >> >>>> parent.......
>> >> >>>> from
>> >> >>>> another iframe.
>> >> >>>>
>> >> >>>> bAvocado=""
>> >> >>>> bButterSquash=""
>> >> >>>> bCauliflower="some data"
>> >> >>>> bCornOnCob=""
>> >> >>>> bCucumber="some more data"
>> >> >>>> bGarlic="more data"
>> >> >>>>
>> >> >>>> the following is in a seperate iframe page
>> >> >>>>
>> >> >>>> <div id="bAvocado"></div>
>> >> >>>> <div id="bButterSquash"></div>
>> >> >>>> <div id="bCauliflower"></div>
>> >> >>>> <div id="bCornOnCob"></div>
>> >> >>>> <div id="bCucumber"></div>
>> >> >>>> <div id="bGarlic"></div>
>> >> >>>>
>> >> >>>> the above would produce this in the iframe that the div's are
>> >> >>>> displayed
>> >> >>>> in.
>> >> >>>>
>> >> >>>> top of page shown by the -----
>> >> >>>>
>> >> >>>>
>> >> >>>> -----------
>> >> >>>>
>> >> >>>>
>> >> >>>> some data
>> >> >>>>
>> >> >>>> some more data
>> >> >>>> more data
>> >> >>>> ======== this is the end of the page.
>> >> >>>>
>> >> >>>>
>> >> >>>> what i would like the display to look like is this.
>> >> >>>>
>> >> >>>> ----------- top of the page
>> >> >>>> some data
>> >> >>>> some more data
>> >> >>>> more data
>> >> >>>>
>> >> >>>>
>> >> >>>>
>> >> >>>>
>> >> >>>> "Murray" <forums@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> >> >>>> news:u0WJWayWFHA.612@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> > The short answer is - you cannot. The longer answer is - if I
>> >> >>>> > had
>> >> >>>> > even a
>> >> >>>> > remote inkling of what you are trying to accomplish, and a
>> >> >>>> > glance
>> >> >>>> > at
>> >> >>>> > some
>> >> >>>> > real code, I might be able to suggest a workaround.
>> >> >>>> >
>> >> >>>> > --
>> >> >>>> > Murray
>> >> >>>> > ============
>> >> >>>> >
>> >> >>>> > <cheers> wrote in message
>> >> >>>> > news:eIUcQRyWFHA.3540@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >> it was only an example of where i wanted things to go.
>> >> >>>> >>
>> >> >>>> >> all i want to find out how i can use the div's when there is
>> >> >>>> >> content in
>> >> >>>> >> them.
>> >> >>>> >> and when the div has nothing in it, it is not used (not
>> >> >>>> >> printed,
>> >> >>>> >> as
>> >> >>>> >> this
>> >> >>>> >> produces a carriage return)
>> >> >>>> >>
>> >> >>>> >>
>> >> >>>> >> thank you
>> >> >>>> >>
>> >> >>>> >> Jason
>> >> >>>> >>
>> >> >>>> >>
>> >> >>>> >>
>> >> >>>> >> "Murray" <forums@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> >> >>>> >> news:ur5z00xWFHA.3184@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>> <scratching head>
>> >> >>>> >>>
>> >> >>>> >>> There are no divs in either file's markup.
>> >> >>>> >>>
>> >> >>>> >>> --
>> >> >>>> >>> Murray
>> >> >>>> >>> ============
>> >> >>>> >>>
>> >> >>>> >>> <cheers> wrote in message
>> >> >>>> >>> news:erV3nwxWFHA.3000@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>>> below are two files i have done to show what i mean.
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>> <html>
>> >> >>>> >>>>
>> >> >>>> >>>> <head>
>> >> >>>> >>>> <title>New Page 1</title>
>> >> >>>> >>>> </head>
>> >> >>>> >>>>
>> >> >>>> >>>> <body>
>> >> >>>> >>>>
>> >> >>>> >>>> <table border="0" cellpadding="0" style="border-collapse:
>> >> >>>> >>>> collapse"
>> >> >>>> >>>> width="1013" id="table1" height="621">
>> >> >>>> >>>> <tr>
>> >> >>>> >>>> <td width="160">this side has the items the were
>> >> >>>> >>>> selected<p>but
>> >> >>>> >>>> it
>> >> >>>> >>>> shows
>> >> >>>> >>>> all the div's and puts a carriage return after them.</p>
>> >> >>>> >>>> <p>i would like the carriage return not to show unless the
>> >> >>>> >>>> div
>> >> >>>> >>>> actually
>> >> >>>> >>>> has some content.&nbsp; (more than &quot;&quot;)</td>
>> >> >>>> >>>> <td><iframe name="I1" src="new_page_2.htm" width="776"
>> >> >>>> >>>> height="581">
>> >> >>>> >>>> Your browser does not support inline frames or is currently
>> >> >>>> >>>> configured
>> >> >>>> >>>> not to display inline frames.
>> >> >>>> >>>> </iframe></td>
>> >> >>>> >>>> </tr>
>> >> >>>> >>>> </table>
>> >> >>>> >>>>
>> >> >>>> >>>> </body>
>> >> >>>> >>>>
>> >> >>>> >>>> </html>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>> <html>
>> >> >>>> >>>>
>> >> >>>> >>>> <head>
>> >> >>>> >>>> <meta http-equiv="Content-Language" content="en-gb">
>> >> >>>> >>>> <meta name="GENERATOR" content="Microsoft FrontPage 6.0">
>> >> >>>> >>>> <meta name="ProgId" content="FrontPage.Editor.Document">
>> >> >>>> >>>> <meta http-equiv="Content-Type" content="text/html;
>> >> >>>> >>>> charset=windows-1252">
>> >> >>>> >>>> <title>New Page 2</title>
>> >> >>>> >>>> </head>
>> >> >>>> >>>>
>> >> >>>> >>>> <body>
>> >> >>>> >>>>
>> >> >>>> >>>> <p>this side has an inline frame and this is where the items
>> >> >>>> >>>> are
>> >> >>>> >>>> selected, and
>> >> >>>> >>>> the div's are defined.</p>
>> >> >>>> >>>> <p>&nbsp;</p>
>> >> >>>> >>>> <p>i have not shown all of the script as it is very
>> >> >>>> >>>> long.</p>
>> >> >>>> >>>>
>> >> >>>> >>>> </body>
>> >> >>>> >>>>
>> >> >>>> >>>> </html>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>> "Murray" <forums@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> >> >>>> >>>> news:%23KMp4jxWFHA.2572@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>>>>> I am printing to one place in one of the tables
>> >> >>>> >>>>>
>> >> >>>> >>>>> Huh? You are printing to a table?
>> >> >>>> >>>>>
>> >> >>>> >>>>>> but it has all the carriage returns in between the
>> >> >>>> >>>>>> letters.
>> >> >>>> >>>>>> how
>> >> >>>> >>>>>> do I
>> >> >>>> >>>>>> remove them? or stop them being printed in the first
>> >> >>>> >>>>>> place.
>> >> >>>> >>>>>
>> >> >>>> >>>>> What does this have to do with divs? Sorry - I'm not
>> >> >>>> >>>>> tracking
>> >> >>>> >>>>> you at
>> >> >>>> >>>>> all....
>> >> >>>> >>>>>
>> >> >>>> >>>>> --
>> >> >>>> >>>>> Murray
>> >> >>>> >>>>> ============
>> >> >>>> >>>>>
>> >> >>>> >>>>> <cheers> wrote in message
>> >> >>>> >>>>> news:O9ddEXxWFHA.3864@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>>>>>I have a table split into 4 equal parts.
>> >> >>>> >>>>>> I am printing to one place in one of the tables, but if
>> >> >>>> >>>>>> lets
>> >> >>>> >>>>>> say
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> you have the letter a to z and only every 5 letter of the
>> >> >>>> >>>>>> alphabet
>> >> >>>> >>>>>> is printed vertically down the table box, and it would
>> >> >>>> >>>>>> look
>> >> >>>> >>>>>> like
>> >> >>>> >>>>>> this
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> e
>> >> >>>> >>>>>> j
>> >> >>>> >>>>>> o
>> >> >>>> >>>>>> t
>> >> >>>> >>>>>> y
>> >> >>>> >>>>>>
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> but it has all the carriage returns in between the
>> >> >>>> >>>>>> letters.
>> >> >>>> >>>>>> how
>> >> >>>> >>>>>> do I
>> >> >>>> >>>>>> remove them? or stop them being printed in the first
>> >> >>>> >>>>>> place.
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> thank you
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> Jason
>> >> >>>> >>>>>>
>> >> >>>> >>>>>>
>> >> >>>> >>>>>>
>> >> >>>> >>>>>> "Murray" <forums@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in
>> >> >>>> >>>>>> message
>> >> >>>> >>>>>> news:ucTNtCuWFHA.3828@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>>>>>>> but it shows a carriage return when they are empty.
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>> Of course. That's because <div> is a block tag. All
>> >> >>>> >>>>>>> block
>> >> >>>> >>>>>>> tags
>> >> >>>> >>>>>>> start on a new line, and force subsequent markup to start
>> >> >>>> >>>>>>> on
>> >> >>>> >>>>>>> a
>> >> >>>> >>>>>>> new
>> >> >>>> >>>>>>> line too.
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>>> how do I get only the div's that have content to print.
>> >> >>>> >>>>>>>> and the ones that are empty prints nothing.
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>> Say more about this. You have multiple pages, each
>> >> >>>> >>>>>>> having
>> >> >>>> >>>>>>> the
>> >> >>>> >>>>>>> same
>> >> >>>> >>>>>>> array of divs, some of which are loaded with content, and
>> >> >>>> >>>>>>> some
>> >> >>>> >>>>>>> of
>> >> >>>> >>>>>>> which are not? And you want those that are 'empty' to not
>> >> >>>> >>>>>>> affect the
>> >> >>>> >>>>>>> screen position of the others? I can't think of a way to
>> >> >>>> >>>>>>> do
>> >> >>>> >>>>>>> that
>> >> >>>> >>>>>>> automatically. Is there a reason why you wouldn't just
>> >> >>>> >>>>>>> delete
>> >> >>>> >>>>>>> them?
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>> --
>> >> >>>> >>>>>>> Murray
>> >> >>>> >>>>>>> ============
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>> <cheers> wrote in message
>> >> >>>> >>>>>>> news:uM5TentWFHA.1384@xxxxxxxxxxxxxxxxxxxxxxx
>> >> >>>> >>>>>>>>I have the following within one of my pages created with
>> >> >>>> >>>>>>>>FrontPage.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> <div id="bAvocado"></div>
>> >> >>>> >>>>>>>> <div id="bButterSquash"></div>
>> >> >>>> >>>>>>>> <div id="bCauliflower"></div>
>> >> >>>> >>>>>>>> <div id="bCornOnCob"></div>
>> >> >>>> >>>>>>>> <div id="bCucumber"></div>
>> >> >>>> >>>>>>>> <div id="bGarlic"></div>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> and it works.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> but it shows a carriage return when they are empty.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> not what I need.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> how do I get only the div's that have content to print.
>> >> >>>> >>>>>>>> and the ones that are empty prints nothing.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>> thank you.
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>>
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>>
>> >> >>>> >>>>>>
>> >> >>>> >>>>>>
>> >> >>>> >>>>>
>> >> >>>> >>>>>
>> >> >>>> >>>>
>> >> >>>> >>>>
>> >> >>>> >>>
>> >> >>>> >>>
>> >> >>>> >>
>> >> >>>> >>
>> >> >>>> >
>> >> >>>> >
>> >> >>>>
>> >> >>>>
>> >> >>>
>> >> >>>
>> >> >>
>> >> >>
>> >> >
>> >> >
>> >>
>> >>
>> >
>> >
>>
>>
>
>


.



Relevant Pages

  • Re: have problems with divs
    ... a html file called showorders.html this is where the script is called from. ... > You don't access the array from the frame, you access the array via a ... >>> changes a selection ... >>> Each time the script fires, it will then rewrite those items to the ...
    (microsoft.public.frontpage.programming)
  • Re: [PHP] Re: How to do this? 6 lines of code...Parse error
    ... > I'd rewrite your other script to store the data in an array. ...
    (php.general)
  • Re: search and replace on an array
    ... In article, ebm ... This is a part of a larger script and I'm not going to rewrite the ... do you have any ideas on how to search and replace on an array? ...
    (comp.lang.perl.misc)
  • Re: How to use Python well?
    ... script, no classes or modules. ... Exploratory programming is pretty normal (though some still insist on ... A rewrite once in a while is not the end of the world, ... helps, as does using tools like pylint, pychecker, pyflakes and/or ...
    (comp.lang.python)
  • Re: Script doctors in for Tom Cruise, Studios custom-tailor projects for the star
    ... Matarese Circle," which potentially matches Cruise with Denzel ... the script doctors in the Cruise derby have been making as much ... who is now rewriting the rewrite that "Matarese Circle" ... technically script doctors because they've been writing these projects ...
    (rec.arts.movies.current-films)