/    Sign up×
Community /Pin to ProfileBookmark

Following code is barebones trying to learn and do what i want. I am populating part of a db. and with success display the rest of the form. My hurdle is figuring out an if statement with data returned to ajax. pasteall code contains the form Need help with the if statement in the success part. line 28.. The code
[url]http://www.pasteall.org/65912/php[/url]

check.php
<?php
$vname = $_POST[‘vname’];
if ($vname==”jim”) {
echo $vname;

}else{
//echo “no”;
}
?>

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@rootMar 07.2016 — First off, JQuery IS NOT JavaScript or AJAX.

if you want to learn then learn JavaScript first and appreciate the difference between a JQuery framework and a Native JavaScript.

JQuery requires that you load a framework that is written in JavaScript that is like a layer of tools, JavaScript that you write that does not use a framework like JavaScript that uses the native (built in to the browser) framework and is much faster, more reliable because you know what you are putting in to the codebase.

I always point out that you are having to download a library / framework each time you load a new page that uses JQuery, it may only be 100Kb but after 10 or so pages, that racks up on data use and for people like me on limited data allowances, visiting many pages that has to load a framework to them be able to run a script, it eats up data like no tomorrow and JQuery is in my browser, responsible for a memory leak, never get the issue where programmers have taken the time to craft a script in JavaScript, always find in my phone the browser crashes and on my computer the browser lock up and looking at the problem under the system monitor see that a page that uses JQuery has memory being used up, CPU being used up and then the browser crashes, if I catch it before its too late the system recovers.

So in a nutshell, learn JavaScript first and then JQuery, you will then see why I hate JQuery.
Copy linkTweet thisAlerts:
@TrainMar 07.2016 — Moved to JQuery forum.
×

Success!

Help @karyoker spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.20,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...