![]() |
PHP cookie and dynamic insertion Hello, I'm trying set cookies for dynamic features. I've been able to get the on page code right that allows me to insert all dynamic features using a custom url string. i.e. http://mysites.com/dynamicpage.php?RA_kw=Keyword- keyword&RA_survey_id=survey_id&RA_id=123&RA_img=im gname As long as ALL variables are present in the incoming url cookie for each variable sets fine. Upon return visits, user is shown all dynamic cookied features. Problem 1: If ALL the php variables are NOT present in the url, cookie doesn't set on individual basis. i.e. http://mysites.com/dynamicpage.php?RA_kw=Keyword-keyword Here's the php code: PHP Code: |
Re: PHP cookie and dynamic insertion Not certain what you want to happen. The reason the variables are not being set is because you are referencing something that isn't there. How can the code $_GET['RA_kw'] from the url when it doesn't exist? |
Re: PHP cookie and dynamic insertion If the data is missing you will need a custom 404 page and let the user know the link cannot be processed as given. |
Re: PHP cookie and dynamic insertion I think we are missing the point. The problem is that it should set some of the variables if they exist. Try showing error/notices and put a die/exit to see the message. It maybe after checking one variable the code crashes. |
| All times are GMT -6. The time now is 11:37 PM. |