<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1003164" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1003164</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/javascript-and-image-display-help-needed#comment-1014005</link>
    <description> &lt;p&gt;hi&lt;/p&gt;
&lt;p&gt;your right, the actual cookie code is in the other file, this is basically a cart script.. a very simple one, the following is the index.html file, above was the product template page, no admin features.. nothing, simple and straight to the point, i just want the images to show up and to i will take out what I dont need after (prices, qty, s/h, etc etc )&lt;/p&gt;
&lt;p&gt;hope you can guide me a litle bit !&lt;/p&gt;
&lt;p&gt;thanks !&lt;/p&gt;
&lt;p&gt;begin code&lt;br /&gt;
***************************&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
 theStuff=&quot;&quot;&lt;br /&gt;
 function startUp(){&lt;br /&gt;
        theStuff=&quot;&quot;&lt;br /&gt;
        theStuff+=&quot;&amp;lt;script&amp;gt;\r&quot;&lt;br /&gt;
        theStuff+=&quot;     function stopErrors(){ \r&quot;&lt;br /&gt;
        theStuff+=&quot;             return true;&quot;&lt;br /&gt;
        theStuff+=&quot;} \r&quot;&lt;br /&gt;
        theStuff+=&quot;window.onerror=stopErrors\r&quot;&lt;br /&gt;
        theStuff+=&quot;&amp;lt;/scr&quot;&lt;br /&gt;
        theStuff+=&quot;ipt&amp;gt;\r&quot;&lt;/p&gt;
&lt;p&gt; }&lt;/p&gt;
&lt;p&gt;        function objectTag(){&lt;br /&gt;
                startUp()&lt;br /&gt;
                return theStuff&lt;/p&gt;
&lt;p&gt;        }&lt;/p&gt;
&lt;p&gt;&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;script language=&quot;javascript&quot;&amp;gt;&lt;/p&gt;
&lt;p&gt;&amp;lt;!-- hide&lt;br /&gt;
order_total =0;&lt;br /&gt;
item_num = 1&lt;br /&gt;
present_item = 1;&lt;br /&gt;
items_ordered = 0;&lt;br /&gt;
total_item_price =0;&lt;br /&gt;
maxarray = 50&lt;br /&gt;
var st_astr = &#039;&amp;lt;html&amp;gt;&amp;lt;body bgcolor=#ffffff&amp;gt;&#039;&lt;br /&gt;
var en_astr = &#039;&amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;&#039;&lt;br /&gt;
grand_total_again = 0;&lt;/p&gt;
&lt;p&gt;function getCookie (name) {&lt;br /&gt;
var dcookie = document.cookie;&lt;br /&gt;
var cname = name + &quot;=&quot;;&lt;br /&gt;
var clen = dcookie.length;&lt;br /&gt;
var cbegin = 0;&lt;br /&gt;
        while (cbegin &amp;lt; clen) {&lt;br /&gt;
        var vbegin = cbegin + cname.length;&lt;br /&gt;
                if (dcookie.substring(cbegin, vbegin) == cname) {&lt;br /&gt;
                var vend = dcookie.indexOf (&quot;;&quot;, vbegin);&lt;br /&gt;
                        if (vend == -1) vend = clen;&lt;br /&gt;
                return unescape(dcookie.substring(vbegin, vend));&lt;br /&gt;
                }&lt;br /&gt;
        cbegin = dcookie.indexOf(&quot; &quot;, cbegin) + 1;&lt;br /&gt;
                if (cbegin == 0) break;&lt;br /&gt;
        }&lt;br /&gt;
return null;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;function setCookie (name, value, expires) {&lt;br /&gt;
        if (!expires) expires = new Date();&lt;br /&gt;
document.cookie = name + &quot;=&quot; + escape (value) +&lt;br /&gt;
&quot;; expires=&quot; + expires.toGMTString() +  &quot;; path=/&quot;;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;function delCookie (name) {&lt;br /&gt;
var expireNow = new Date();&lt;br /&gt;
document.cookie = name + &quot;=&quot; +&lt;br /&gt;
&quot;; expires=Thu, 01-Jan-70 00:00:01 GMT&quot; +  &quot;; path=/&quot;;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;var shiparray =  new parent.createArray(10);&lt;/p&gt;
&lt;p&gt;function getCookieArray(name){&lt;br /&gt;
var i = 0;&lt;br /&gt;
        while (getCookie(name + i) != null) {&lt;br /&gt;
        shiparray[i + 1] = getCookie(name + i);&lt;br /&gt;
        i++;&lt;br /&gt;
                shiparray.length = i;&lt;br /&gt;
        }&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt; var expdate = new Date();&lt;/p&gt;
&lt;p&gt; expdate.setTime (expdate.getTime() +  (24 * 60 * 60 * 1000 * 365)); &lt;/p&gt;
&lt;p&gt;function setCookieArray(name){&lt;br /&gt;
    temp_length = setCookieArray.arguments.length - 1;&lt;br /&gt;
        for (var i = 0; i &amp;lt; temp_length; i++) {&lt;br /&gt;
        data = setCookieArray.arguments[i + 1]&lt;br /&gt;
        setCookie (name + i, data, expdate);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;/p&gt;
&lt;p&gt;function go_with_cookie()&lt;br /&gt;
{&lt;br /&gt;
setCookieArray(&#039;gifttails&#039;,&lt;br /&gt;
parent.ship_details.f_namea,&lt;br /&gt;
parent.ship_details.l_namea,&lt;br /&gt;
parent.ship_details.email,&lt;br /&gt;
parent.ship_details.ad_onea,&lt;br /&gt;
parent.ship_details.ad_twoa,&lt;br /&gt;
parent.ship_details.citya,&lt;br /&gt;
parent.ship_details.statea,&lt;br /&gt;
parent.ship_details.countrya,&lt;br /&gt;
parent.ship_details.zipa);&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;function get_that_cookie()&lt;br /&gt;
{&lt;br /&gt;
var i;&lt;br /&gt;
getCookieArray(&#039;gifttails&#039;);&lt;br /&gt;
//alert(&#039;shiparray.length = &#039;+ shiparray.length);&lt;br /&gt;
for (i=0;i&amp;lt;shiparray.length+1;i++)&lt;br /&gt;
    {if (shiparray[i])&lt;br /&gt;
          { //alert(&#039;ship_array[&#039; + i + &#039;] =&#039;+ shiparray[i]);&lt;br /&gt;
        ship_details[i]  = shiparray[i];&lt;br /&gt;
                //alert(&#039;ship_details[&#039; + i + &#039;] =&#039;+ ship_details[i]);&lt;br /&gt;
          }&lt;br /&gt;
          else&lt;br /&gt;
          {// to initiate array values&lt;br /&gt;
           ship_details[i] = &#039;&#039;&lt;br /&gt;
          }&lt;br /&gt;
    }&lt;/p&gt;
&lt;p&gt;parent.ship_details.f_namea = ship_details[1];&lt;br /&gt;
parent.ship_details.l_namea = ship_details[2];&lt;br /&gt;
parent.ship_details.email = ship_details[3];&lt;br /&gt;
parent.ship_details.ad_onea = ship_details[4];&lt;br /&gt;
parent.ship_details.ad_twoa = ship_details[5];&lt;br /&gt;
parent.ship_details.citya = ship_details[6];&lt;br /&gt;
parent.ship_details.statea = ship_details[7];&lt;br /&gt;
parent.ship_details.countrya = ship_details[8];&lt;br /&gt;
parent.ship_details.zipa = ship_details[9];&lt;/p&gt;
&lt;p&gt;//alert(&#039;shiparray length= &#039; + shiparray.length + &#039;\nshiparray[1] = &#039; + shiparray[1] + &#039;\nshiparray[2] = &#039; + shiparray[2] + &#039;\nshiparray[3] = &#039; + shiparray[3] + &#039;\nshiparray[4] = &#039; + shiparray[4] + &#039;\nshiparray[5] = &#039; + shiparray[5] + &#039;\nshiparray[6] = &#039; + shiparray[6] + &#039;\nshiparray[7] = &#039; + shiparray[7] + &#039;\nshiparray[8] = &#039; + shiparray[8]);&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;// shipping details object creation&lt;/p&gt;
&lt;p&gt;ship_details = new shipp_details();&lt;/p&gt;
&lt;p&gt;function shipp_details()&lt;br /&gt;
{&lt;/p&gt;
&lt;p&gt;this.f_namea = &#039;&#039;&lt;br /&gt;
this.l_namea= &#039;&#039;&lt;br /&gt;
this.ad_onea = &#039;&#039;&lt;br /&gt;
this.ad_twoa = &#039;&#039;&lt;br /&gt;
this.citya = &#039;&#039;&lt;br /&gt;
this.statea =&#039;&#039;&lt;br /&gt;
this.zipa = &#039;&#039;&lt;br /&gt;
this.countrya = &#039;&#039;&lt;br /&gt;
this.phonea = &#039;&#039;&lt;br /&gt;
this.faxa = &#039;&#039;&lt;br /&gt;
this.mailon = false&lt;br /&gt;
this.sameflag = false&lt;br /&gt;
this.shipname=&#039;&#039;&lt;br /&gt;
this.ad_oneb = &#039;&#039;&lt;br /&gt;
this.ad_twob=&#039;&#039;&lt;br /&gt;
this.shipb = &#039;&#039;&lt;br /&gt;
this.stateb=&#039;&#039;&lt;br /&gt;
this.zipb=&#039;&#039;&lt;br /&gt;
this.countryb=&#039;&#039;&lt;br /&gt;
this.phoneb=&#039;&#039;&lt;br /&gt;
this.faxb=&#039;&#039;&lt;br /&gt;
this.email=&#039;&#039;&lt;br /&gt;
this.comments = &#039;&#039;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;function refresh_ship_details(shipform)&lt;br /&gt;
{&lt;br /&gt;
parent.main.document.order.comments.value = shipform.comments&lt;br /&gt;
parent.main.document.order.name_first.value= shipform.f_namea&lt;br /&gt;
parent.main.document.order.name_last.value= shipform.l_namea&lt;br /&gt;
parent.main.document.order.email.value=shipform.email&lt;br /&gt;
parent.main.document.order.address1.value=shipform.ad_onea&lt;br /&gt;
parent.main.document.order.address2.value=shipform.ad_twoa&lt;br /&gt;
parent.main.document.order.city.value=shipform.citya&lt;br /&gt;
parent.main.document.order.state.value=shipform.statea&lt;br /&gt;
parent.main.document.order.zip.value=shipform.zipa&lt;br /&gt;
parent.main.document.order.country.value=shipform.countrya&lt;br /&gt;
parent.main.document.order.phone.value=shipform.phonea&lt;br /&gt;
parent.main.document.order.fax.value=shipform.faxa&lt;br /&gt;
parent.main.document.order.mail_list.value=shipform.mailon&lt;br /&gt;
parent.main.document.order.same_flag.value=shipform.sameflag&lt;br /&gt;
parent.main.document.order.ship_name.value=shipform.shipname&lt;br /&gt;
parent.main.document.order.ship_address1.value=shipform.ad_oneb&lt;br /&gt;
parent.main.document.order.ship_address2.value=shipform.ad_twob&lt;br /&gt;
parent.main.document.order.ship_city.value=shipform.shipb&lt;br /&gt;
parent.main.document.order.ship_state.value=shipform.stateb&lt;br /&gt;
parent.main.document.order.ship_zip.value=shipform.zipb&lt;br /&gt;
parent.main.document.order.ship_country.value=shipform.countryb&lt;br /&gt;
parent.main.document.order.ship_phone.value=shipform.phoneb&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;function add_ship_details(shipform)&lt;br /&gt;
{&lt;/p&gt;
&lt;p&gt;shipform.comments = parent.main.document.order.comments.value&lt;br /&gt;
shipform.f_namea = parent.main.document.order.name_first.value&lt;br /&gt;
shipform.l_namea= parent.main.document.order.name_last.value&lt;br /&gt;
shipform.email = parent.main.document.order.email.value&lt;br /&gt;
shipform.ad_onea = parent.main.document.order.address1.value&lt;br /&gt;
shipform.ad_twoa = parent.main.document.order.address2.value&lt;br /&gt;
shipform.citya = parent.main.document.order.city.value&lt;br /&gt;
shipform.statea =parent.main.document.order.state.value&lt;br /&gt;
shipform.zipa = parent.main.document.order.zip.value&lt;br /&gt;
shipform.countrya =parent.main.document.order.country.value&lt;br /&gt;
shipform.phonea = parent.main.document.order.phone.value&lt;br /&gt;
shipform.faxa = parent.main.document.order.fax.value&lt;br /&gt;
shipform.mailon = parent.main.document.order.mail_list.value&lt;br /&gt;
shipform.sameflag = parent.main.document.order.same_flag.value&lt;br /&gt;
shipform.shipname=parent.main.document.order.ship_name.value&lt;br /&gt;
shipform.ad_oneb = parent.main.document.order.ship_address1.value&lt;br /&gt;
shipform.ad_twob=parent.main.document.order.ship_address2.value&lt;br /&gt;
shipform.shipb = parent.main.document.order.ship_city.value&lt;br /&gt;
shipform.stateb=parent.main.document.order.ship_state.value&lt;br /&gt;
shipform.zipb=parent.main.document.order.ship_zip.value&lt;br /&gt;
shipform.countryb=parent.main.document.order.ship_country.value&lt;br /&gt;
shipform.phoneb=parent.main.document.order.ship_phone.value&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;// end of shipping details object handling&lt;/p&gt;
&lt;p&gt;function&lt;/p&gt;
 </description>
     <pubDate>Mon, 05 Jun 2000 20:28:00 +0000</pubDate>
 <dc:creator />
 <guid isPermaLink="false">comment 1014005 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/javascript-and-image-display-help-needed#comment-1014006</link>
    <description>  </description>
     <pubDate>Mon, 05 Jun 2000 20:28:00 +0000</pubDate>
 <dc:creator />
 <guid isPermaLink="false">comment 1014006 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/javascript-and-image-display-help-needed#comment-1014007</link>
    <description>  </description>
     <pubDate>Mon, 05 Jun 2000 20:28:00 +0000</pubDate>
 <dc:creator />
 <guid isPermaLink="false">comment 1014007 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/javascript-and-image-display-help-needed#comment-1014004</link>
    <description> &lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;  Maybe I&#039;m going blind, but I see no code for the cookie, nor any reference for &#039;code&#039; other than in write_to_field() function.&lt;br /&gt;
   How are you maintaining your images? In an array? Are they hooked to the product names? or a product id? Why not add the image srcURL to the cookie? You will need to save space for the image, or put up a different page entirely.&lt;br /&gt;
   If you have an array set up as follows:&lt;br /&gt;
 var products = new Array();&lt;br /&gt;
  products[0] = productID;&lt;br /&gt;
  products[1] = productName;&lt;br /&gt;
  products[2] = imageSrc;&lt;br /&gt;
  ....&lt;br /&gt;
you can access the image with:&lt;/p&gt;
&lt;p&gt;  for (i = 0; i &amp;lt; products.length; i+3)&lt;br /&gt;
  {&lt;br /&gt;
     if (product[i] == productName)&lt;br /&gt;
     {&lt;br /&gt;
         imageSrc = products[i+2]&lt;br /&gt;
         break;&lt;br /&gt;
      }&lt;br /&gt;
  }&lt;br /&gt;
Then you need to load the image:&lt;/p&gt;
&lt;p&gt;   image.src = imageSrc;&lt;/p&gt;
&lt;p&gt;Hope this helps&lt;br /&gt;
Vinny&lt;/p&gt;
&lt;p&gt;------------------&lt;br /&gt;
my site:&lt;a href=&quot;http://members.aol.com/grassblad&quot; class=&quot;bb-url&quot;&gt;GrassBlade: cut&amp;amp;paste javascript&lt;/a&gt;&lt;br /&gt;
moderator at:&lt;a href=&quot;http://www.javaplace.co.uk&quot; class=&quot;bb-url&quot;&gt;The Javascript Place&lt;/a&gt;&lt;br /&gt;
&lt;A target=&quot;_blank&quot;&gt;Javascript City&lt;/a&gt;&lt;/p&gt;
 </description>
     <pubDate>Mon, 05 Jun 2000 19:05:00 +0000</pubDate>
 <dc:creator>Vincent Puglia</dc:creator>
 <guid isPermaLink="false">comment 1014004 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
