Find Jobs
Hire Freelancers

PHP & JS Session Varialbe

$10-30 USD

Closed
Posted about 5 years ago

$10-30 USD

Paid on delivery
Quick project for someone skilled in php and js. THIS WORKS .................... var parameters = { serveraddress: '[login to view URL]', // Manual manipulation works username: 'testuser', // Manual manipulation works password: '00e2ac36b356df4616b6ecb6', // Manual manipulation works loglevel: 5 }; THIS Fails ....................I need this to be dynamic and get the username from the php session variable... var parameters = { var sesstest = "<?php echo $_SESSION['username']; ?>"; // This is a Session variable -- I can see username and echo it in php. serveraddress: '[login to view URL]', username: sesstest, // This fails. If I place it in single quotes = fail. Double quotes = fail. password: '00e2ac36b356df4616b6ecb6', loglevel: 5 }; In my php, I have this before the src load of the .js <script type="text/javascript"> var sesstest='<?php echo $_SESSION['username'];?>'; </script> How do I get the session variable into JS and what is the proper format for js Colon parmater with variables?
Project ID: 19054766

About the project

15 proposals
Remote project
Active 5 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
15 freelancers are bidding on average $20 USD for this job
User Avatar
Hi there, Quick fix. I know how to fix the JS errors. I have a 99% project completion rate and a 4.99 reputation (out of max 5.0!) from more than 1150 projects from a period of 12 years. Thanks. I look forward to hearing from you! Best Regards, Rajesh Soni.
$25 USD in 0 day
5.0 (1032 reviews)
8.8
8.8
User Avatar
Hello, I'm Abu Gosia. I'm interesting your project very well. I m quite well experienced in these jobs. Let's go ahead with me. Thanks
$15 USD in 0 day
4.9 (189 reviews)
6.9
6.9
User Avatar
Hi I know exactly how to do this task. So then let me know when we could start. I'm ready to start right now. Regards
$25 USD in 0 day
4.9 (105 reviews)
6.3
6.3
User Avatar
Hi, I have more than 13 years experience in PHP and Javascript. I see the code you posted, and I can confirm I can fix this issue within half hour, so feel free to contact me if you want this to be fixed quickly.
$15 USD in 1 day
5.0 (61 reviews)
6.1
6.1
User Avatar
Hello I'm the full stack developer. I understood all about your job. so there is no problem for me to complete your project with my skill. I can do work your job perfectly. Hope to work with you as soon as possible. Best regards
$25 USD in 1 day
4.9 (71 reviews)
5.8
5.8
User Avatar
I believe in providing good quality code and services with security. I am a Web Security Researcher & Bug Bounty Hunter at HackerOne, BugCrowd, BountyFactory and many other Independent Bug Bounty Programs Reported Security Vulnerabilities to Google, Facebook, Twitter, TCS, DigitalOcean, Magento, Nexmo and many other Companies Listed in more than 30 Company's Hall of Fame for reporting Security Vulnerabilities and reported more than 200 Security Vulnerabilities Web Security : OWASP, BurpSuite, Kali Linux, BugCrowd VRT, MetaSploit + HTML5, CSS3 + jQuery, Javascript, Ajax + Angular JS, React JS + Website design + Bootstrap, Responsive design + PHP + ColdFusion + MYSQL + Magento + Joomla + Laravel + Wordpress + Dot Net + CodeIgniter Development + User Interface / IA, Graphic Design, Logo design + PSD to HTML + Web Security + Penetration Testing + Ethical Hacking + Linux : CentOS, RedHat, Ubuntu + Windows Server + Vulnerability Assessment PS : No illegal Hacking.
$20 USD in 1 day
5.0 (107 reviews)
5.3
5.3
User Avatar
Dear Clients! I having 5+ years of experience, focused on success, high-quality work, and continued growth. I'm a full-stack developer. Here are my skills: - Work in : + Webservices with Restful, SOAP. + PhotoShop, Illustrator, Dreamweaver, ... + Mobile Apps (Android & iOS), ... + Ionic, AngularJS, React(JS & Native), NodeJS, ... + PHP & MYSQL, HTML5, CSS3, JavaScript, jQuery, XML, JSON. + eCommerce, WordPress, Open Cart, Shopify, ... + Framework PHP CakePHP, Codeigniter, Laravel, Yii, Symfony 2,3, ... + Git. + Linux Server. - Advanced and best CMS Wordpress: + Install and config the project. + Plugin: Customize and create new plugin. + Template: Create, adjust the template (include design graphics or not) + Migrate & Upgrade: sustainable development and long-term. + Advanced SEO (search engine optimization). Please award this job to me. I can do it perfectly. Kind Regards, Van Phu.
$20 USD in 1 day
4.9 (17 reviews)
4.3
4.3
User Avatar
You need to make an AJAX call to the PHP system to return the values from PHP like a JSON data and use the JSON data in your JavaScript. Thanks
$20 USD in 2 days
4.9 (21 reviews)
3.9
3.9
User Avatar
hi, hope you are doing good. I have extensive experience with Php javascript. would be happy to work with you in an hour. thanks
$15 USD in 1 day
5.0 (9 reviews)
3.1
3.1
User Avatar
Hey, I've delt with this before and I'm willing to explain how to safely use sessions with JS. Please contact me if You wish to collaborate. Cheers, Gvozden Despotovski
$15 USD in 1 day
5.0 (1 review)
0.8
0.8
User Avatar
Hi, I solved your problem :) If you interested get contact .........................................
$25 USD in 0 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Low prices because I am new to this platform and I need to create a good reputation I need to work individually and no longer for companies My way of working is the following We create the design and I'll show it to you if you tell me what's ready then I start with the bakend and I program everything and I hand you the project in the agreed time
$20 USD in 2 days
0.0 (0 reviews)
0.0
0.0
User Avatar
Hello. Sometimes this integration of PHP with JS can bring some headaches. I have faced several similar problems to yours and I can solve this for you. I am at your disposal.
$20 USD in 1 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Hi, Is your username contains single or double quote...? Can I see error details...
$15 USD in 0 day
5.0 (1 review)
0.0
0.0

About the client

Flag of UNITED STATES
Biloxi, United States
5.0
8
Payment method verified
Member since Nov 2, 2015

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.