Hello,
I require some help with merging 2 js scripts to make them fire together.
Logic:
The first script is an analytics script and it fires on page load(no change required). The Second script and associated html/css needs to be packaged in a way that it fires when scroll depth is 75%. Once the survey is submitted. The Data collected on survey form then need to updated on keen tag (elements below).
First Script
<scrXXX crossorigin src="[login to view URL]@4"></scrXXX>
<scrXXX>
client = new KeenTracking({
projectId: 'XXXXXXXXXXXXXX',
writeKey: 'XXXXXXXXXXXXX'
});
[login to view URL](function(){
return {
app: {
version: '4.1.5'
},
user: {
age: [login to view URL]([login to view URL]() * (70 - 15 + 1)) + 15,
gender: ([login to view URL]() >= 0.5 ? "Male" : "Female")
}
/* Custom properties for all events */
};
});
[login to view URL]('pageviews', function(){
return {
page: {
brief_id: [login to view URL]([login to view URL]()*10) + 1000,
article_name: [login to view URL]([login to view URL]()*3) + 1
/*ADD SURVEY FIELDS HERE*/
}
/* Custom properties for pageviews event */
};
});
[login to view URL]();
</scXXXX>
------------------------------------------------------------------------------------------
Second tag SURVEY
<!-- Your platform (jquery) scripts. -->
<scXXX src="[login to view URL]"></scXXX>
---
<div id="surveyContainer"></div>
---
[login to view URL] = "bootstrap";
var surveyJSON = {title:"Fabulate Survey",pages:[{name:"page1",elements:[{type:"rating",name:"question1",title:"How likely are to to BUY?"},{type:"rating",name:"question2",title:"How Likely are you to SHARE"},{type:"radiogroup",name:"question3",title:"Gender",choices:[{value:"item1",text:"Female"},{value:"item2",text:"Male"}]},{type:"dropdown",name:"question5",title:"Age?",choices:[{value:"item1",text:"18-25"},{value:"item2",text:"26-35"},{value:"item3",text:"36-50"},{value:"item4",text:"50 and above"}]}]}]}
function sendDataToServer(survey) {
[login to view URL]('68937f24-98ed-40c0-b820-1d01902aa6ff');
}
var survey = new [login to view URL](surveyJSON);
$("#surveyContainer").SurveyWindow({
model: survey,
onComplete: sendDataToServer
});
Dear,
I am Jin S, WEB developer in China.
I've just read your job posting and I’m very interested.
I'm a certificated freelancer with almost 1000 good reviews from clients.
I have experienced knowledge in every part of WEB technology such as Laravel and Angular.js.
I know how to bring your idea alive and communication well.
I never disappoint my clients and I’m able to lead your project to success.
I am sure these will reflect in my past results.
Please contact me if I am a match for you are looking for.
Best Regards,
Smile
Hi there.
Nice to meet you.
I'm a Javascript expert and FULL Time Developer.
I have checked your requirements carefully.
I have rich experience in Javascript, PHP, Html, CSS, JS UI design, etc.
I can start work immediately now for you and can provide you perfect result for your requirements.
Please let's discuss your project and reasonable price for this project in more detail.
Thanks.
Dear, sir
I've read your specification carefully and I'm very interested in your job.
I have rich experience of developing web projects for 5 years
using PHP and JS.
I ensure high quality and deadline.
I would like to have a detailed conversation with you
regarding this project to see where we can fit in.
Thanks for taking time to read my proposal.
I am ready to begin immediately.
Kind regards,
Pavel
Hello,
I have gone through your job posting and become very much interested to work with you. I am an expert in this field. I have already completed several projects like this. For evidence you can see my profile.
Please visit : https://www.freelancer.com/u/schoudhary1553
I have excellent command over English. I am a hard worker, productive and worthy of your attention I hope, I would be the right candidate for this post. Awaiting an affirmative response from you.
Kinds Regards,
Sandeep
Hi sir! Contact with me then I can show you my portfolio.
I am interested to work with you.
I can provide you professional graphic/web design and Illustrator services.
I can design for you according to your requirements. I will give you unlimited revision until you will not satisfy for your design.I will deliver you this according to your time frame after your award.
I can assure you several things.
* I have expertise in Twitter Bootstrap, Angular, HTML5/CSS3, Php, SASS, LESS, wordpress ....
* I have a great web development sense.
* Well organized and clean code easy to understand.
* Fully responsive, optimized and SEO semantic code.
* Validate according to w3c standards.
* High quality graphic design.
* I can start it immediately.
* Compatible with all modern browsers and mobile devices.
I have 5+ years experience as front end developer.
Looking forward to hearing from you soon.
Thanksq
Hi there.
I am very interested in your proposal.
I can instantly help you with your starting project with a successful completion.
As a professional developer, I ensure for a perfect ongoing project.
I am sure that I can help you
Looking forward to meeting you on chat.
Regards
Hello,
I'm ready to start immediately and I can done project fast,
I have big experience for it (14 years). I have experience with to CSS, HTML, HTML5, Javascript. My hourly rate is 20$
I’m an experienced programmer in PHP and have multiple years of experience in Frameworks such as FuelPHP, Zend Framework, CodeIgniter and Laravel, I’m also experienced in front end technologies such as jQuery and Javascript and I’m confident that I will be a great asset for your project.
Hi ,
Hope you are doing well.
I am excited to work on this project.I read a description and i will complete the project in 1 day. I am web developer and having 3 years of experience.
Expert:
1. Wordpress , PHP, C# , HTML ,Javascript, MYSQL - MSSQL.
Please give me an opportunity.
Thanks
It's interesting feature. I am assuming that I am going to dealing with only second script without touching first script.
We can talk about that deeply like the definition of percentage of scroll depth (What I think is start measure from top of browser, but some people might not think the same way)
Hi
I am skilled and experienced web developer. I can provide you quality work with in estimated time.
if you are interested I can also give demo for some of my previous websites I worked on.
Thanks
Regards
Bhagawat Dongre