|
I have these marketing campaigns running (like google adwords) and based on where a user comes from (google, yahoo, mns-bing, facebook) I have this referrer code passed that I collect out of the URL and I put a cookie on the user's computer based on what is included in this tag. OK so now I have to get the the cookie (which I know how to do) and based on if this cookie says website I need to show a drop down with sources for the user to choose from. That is my delimna. I typically code in PHP but this site wasn't developed by me so this cookie tracking was done in javascript. My issue is normally in PHP I can say if(referrer==website) then close off the php code and then go into the HTML but that doesn't seem to work for javascript. Can someone help me with this please?
What I"m doing is retrieving the cooking and now all I want to do is say if the cookie is website show this drop down menu. The code that is currently on the site is attached.
[CODE]<script>
function getCookie(c_name)
{
if (document.cookie.length>0)
{
c_start=document.cookie.indexOf(c_name + "=");
if (c_start!=-1)
{
c_start=c_start + c_name.length+1;
c_end=document.cookie.indexOf(";",c_start);
if (c_end==-1) c_end=document.cookie.length;
document.inquiry.referer.value = unescape(document.cookie.substring(c_start,c_end));
return false;
}
}
document.inquiry.referer.value = 'Website';
}
jQuery(document).ready(function() {
getCookie('referer');
});
</script>
[/CODE]
The drop down I want to show is:
[HTML]<select name=How_did_you_find_us>
<option value=''>Please Select</option>
<option value=Billboard>Billboard</option>
<option value=Direct Mail>Direct Mail</option>
<option value=Facebook>Facebook</option>
<option value=High School Presentation>High School Presentation</option>
<option value=Internet/Search Engine>Internet Search</option>
<option value="Magazine">Magazine</option>
<option value="MySpace">MySpace.com</option>
<option value="Newspaper">Newspaper</option>
<option value="Poster">Poster</option>
<option value="Radio">Radio</option>
<option value="Referral">Referral</option>
<option value="TV">TV</option>
<option value="Yellow Pages">Yellow Pages</option>[/HTML]
|
|
|
I want the datetimepicker on ecah row on the table
If I give the unique Id in the jsp page and js, the cursor still pointing to only prev textbox.
Here is the detail code:
the below is the html code
<html:text property="DateTime" size="18" styleClass="maincontent1" value="" /><a href="javascript:NewCssCal('DateTime','yyyymmdd','arrow',true,24,false);"><img src="images/cal.gif" width="16" height="16" border="0" alt="Pick a date"> </a
For the above code I need to add a date picker for next row.
I did like below.
Var iarr = āDate Timeā;
Count = 0;
oCell.innerHTML = "<input type='text' name='"+iarr+"' id='"+iarr+"' size='18' class='maincontent1' ><a href=javascript:NewCssCal(\"" +iarr+ "\",\"yyyymmdd\",\"arrow\",true,24,false)><img src='images/cal.gif' width='16' height='16' border='0'alt='Pick a date'> </a> ";
count = count+1;
iarr = iarr+ count;
oCell = newRow.insertCell;
With the above code the cursor control pointing to the previous.
Do you have any solution for this? Please let me know
thanks
|
|
|
Once produced the cookies they appear to be warm and tasty but thats not it!
you will then need to protect the cookies with all your might from the evil cookie monster who will come once he smells them cookies IF you succed in protecting your cookies you may eat in content BUT if you fail then you will die and have all you cookies eaten by the fiend.
====================== Breast Enhancement Cream | Breast Enhancement Pills
|
|
|
|
|
|
|
|