Write a script generating codes
Hello, need the following script :
For example – a visitor comes to your site on one of the link resembles the following :
only interesting values utm_source, utm_campaign, utm_content and utm_term (values may be different)
Need to generate unique 6 digit code composed of 2 uppercase English letters and 4 digits (for example AY3491) and write to file the following (respectively):
DDMMYY:HHMMSS,AY3491,utm_source=yandex,utm_campaig n=13706944,utm_content=1069137603,utm_term=sausages
DDMMYY:HHMMSS,AY3491,utm_source=google utm_campaig n=65987412,utm_content=7980803808,utm_term=sausages
DDMMYY:HHMMSS,AY3491,utm_source=avito
DDMMYY:HHMMSS,AY3491
Myself with the generated code needs to be shown in a floating window, in the upper right corner of the site in the form of "Code AY3491"
Now the most important thing. If a visitor comes to your site repeatedly, the visitor needs to show the code that was generated when a visitor went to the site for the first time. Accordingly in the file to write the same data when a visitor went to the site for the first time.
The script plan to implement in Joomla site, but I think it does not matter.
16.03.2016 23:24