pzuurveen 90 Posting Whiz in Training

you are making 2 calls to call.php
first has post variables:
xhr.send("amount=" + transferTotal + "&name=" + name);

second does not:
window.open('https://mydomain.com/con.php', '_blank');

pzuurveen 90 Posting Whiz in Training

$_SESSION gets set by session_start()
before that is empty
So:

<?php
    session_start();
    header("Content-Type: application/json");
    header("Access-Control-Allow-Credentials: true");
    header("Access-Control-Allow-Origin: null");

    if (isset($_SESSION))
    {
        $_SESSION["time"] = time();
        if (isset($_SESSION["time"])) echo json_encode("Session exists:" .$_SESSION["time"]);   
    }
    else
    {
        echo json_encode("Session does not exist!");
    }
pzuurveen 90 Posting Whiz in Training

Why not use explode

pzuurveen 90 Posting Whiz in Training

remove the style="display:none;" from

    <ul id="playlist1" style="display:none;">
        <?=$output?>
    </ul>
diafol commented: Still laughing. Heh heh. +15
pzuurveen 90 Posting Whiz in Training
if (isset($_POST['chkNumberck'])) $returnArray=$_POST['chkNumberck'];
else $chkNumberck= array();
$count=5;

echo"<form action='test.php' method='post'>";
for ($sub_id=0 ;$sub_id < $count;$sub_id+=1) 
    {
    echo "<input type='checkbox' name='chkNumberck[]'  value=$sub_id "; 
    if (in_array($sub_id,$chkNumberck)) echo"checked='checked'";>
    }
echo "<input type='submit' /></form>";
pzuurveen 90 Posting Whiz in Training

also:

echo "<td><a id='more' href='http://www.niloofar3D.ir' onClick='return popup(this, \"mypopup\")'><button>&raquo;</button></a></td>";
pzuurveen 90 Posting Whiz in Training

according to the manual: operators precedence

it has an 'Undefined order of evaluation'
and may 'change between versions of PHP or depending on the surrounding code'

diafol commented: Good link. Thought I was going insane. Well maybe I am, but not 'coz of this! +15
pzuurveen 90 Posting Whiz in Training
pzuurveen 90 Posting Whiz in Training

something is wrong at around line 228

if (isset($_POST['type'])) {
    if ($_POST['type'] == "login")
}

change to

if (isset($_POST['type'])) {
        if ($_POST['type'] == "login") {
        // do something 
        // like displaying your login form
        }
    }
pzuurveen 90 Posting Whiz in Training
$id =$_POST['user_id'];
rubberman commented: Posting answers is good. Posting with explanations is better. +12
pzuurveen 90 Posting Whiz in Training

make sure your browser points to http://localhost/yourfile.php and NOT file://c:/wamp/htdocs/yourfile.php

pzuurveen 90 Posting Whiz in Training
<?php
session_start();

must be the at the very top of youre script.
no html before it, not even a white-line;

for actual error message:
if just you run session1.php, $_POST will be empty.
test: var_dump($_POST);
the $_POST is filled bij the form only after you submit it
but action="session2.php" will redect to session2.php
so in session2.php $_POST['text'] will have the value input in the form.
So no need for $_SESSION.

pzuurveen 90 Posting Whiz in Training

should it be :
$mail->Port = 465; //port secure ssl email

pzuurveen 90 Posting Whiz in Training
if(!empty($stu_fname) &&
   !empty($stu_lname) && 
   !empty($stu_email) && 
   !empty($stu_telp)  && 
   !empty($stu_skype) )  {
pzuurveen 90 Posting Whiz in Training

You never execute the update query

$s="UPDATE finance SET credit ='" . $r. "'  WHERE payee = 'rw'";
$res = mysql_query($s) or die(mysql_error());
pzuurveen 90 Posting Whiz in Training

That just turns off any error message below E_PARSE level.
It doesnot solve the error.

pzuurveen 90 Posting Whiz in Training

sleep
also check out
set-time-limit

pzuurveen 90 Posting Whiz in Training
pzuurveen 90 Posting Whiz in Training

works:

$keys = array('key1', 'key2', 'key3');
$value = 'some value';
$string='$md';
foreach($keys as $index => $key)
    {   
    $string.="['$key']";
    }
 $string.= '=$value;';
 eval($string);
 var_dump($md); 

but:

If eval() is the answer, you're almost certainly asking the
wrong question. -- Rasmus Lerdorf, BDFL of PHP

pzuurveen 90 Posting Whiz in Training

the same as this post this post

See that you didn't change to

if ($child->getName() == "URL")
$url = (string) $child; 

have you done a var_dump('$gateway_url'); yet?
post the result

pzuurveen 90 Posting Whiz in Training
  • install xampp
  • install wordpress
  • install same plugins as on your hosted wp
  • export data frorm hosted wp (admin/extra)
  • import data on local wp
    and you have a copy of your website on local host
pzuurveen 90 Posting Whiz in Training

there can be no output , or even empty lines outside <?php ?> before

session_start();

so do as veedeoo tells you and put it at the top of the page

<?php
session_start();
?>
<!DOCTYPE html>
<html>
pzuurveen 90 Posting Whiz in Training

I don't think or die(mysql_error() works here because you access the mysql not though php but though the shell.
to get te result back from the shell

exec('command', $result);
var_dump($result);
pzuurveen 90 Posting Whiz in Training

vars inside ' ' are treated as plain text
vars inside " " are treated as var
so
should work

echo "<img src='libchart-1.3\libchart\demo\generated\demo25_$email.gif'>";

also posible

echo '<img src="libchart-1.3\libchart\demo\generated\demo25_'.$email.'.gif">';
pzuurveen 90 Posting Whiz in Training

change the ` (back tick) in the query value part to ' (single qoute)
stings are surounde by a single qoute.
Colomnames by a back tick

pzuurveen 90 Posting Whiz in Training

look to me that company/vision-mission.html get redirected to company.php?pageSlug=vision-mission

in company the vision-mision page is fechted for the data base:

wdsQuery("SELECT pages_ID, pages_title, pages_description, pages_content, pages_slug FROM " . $dbtable['pages'] . " WHERE pages_slug = '" . slugs($_GET['pageSlug']) . "'");

and echoed:

echo $r['pages_content'];
pzuurveen 90 Posting Whiz in Training

N is the number of levels of subdirectory used.
"N;/temp" makes no sence.
3; /temp does, but is not necessary and not recommended, so do you reley need it?
see php#ini.session.save-path

pzuurveen 90 Posting Whiz in Training

no.
php runs on the server.
Then the html & javaschript output is sent to the browser.
The browser runs the javascript.

to get the javascript valus back to the server you can use ajax.
jQuey makes it easyer

pzuurveen 90 Posting Whiz in Training

your html

<p><label for="img1">صورة 1</label>
<input type="file" name="img[]" id="fileField1" />
<input type="text" name="label[]" id="Limage1" placeholder="Add label">
</p>

your php

...
$tmp_name = $_FILES["img"]["tmp_name"][$key];
$name = $_FILES["img"]["name"][$key];

$label = $_POST['label'][$key];

....
// change your query to save $label in your db

if($result){
    // header('Location:includes/pan/projects/google/face.php?propid='.$p);
    // cant redirect, have to do 4 more images
}else{
echo"Error";
}
...
pzuurveen 90 Posting Whiz in Training

first create te code in html to make sure you get what you want.
Then create that html-code using javascript with document.createElement

nouth commented: thanks :) +1
pzuurveen 90 Posting Whiz in Training
pzuurveen 90 Posting Whiz in Training

line 5

 if($email == $row1['email'])

and what are you trying to do on line 4?

pzuurveen 90 Posting Whiz in Training
pzuurveen 90 Posting Whiz in Training

also check out mysql_real_escape_string
(will not solf your problem but prevent hacking)

pzuurveen 90 Posting Whiz in Training

in json the name also has to be inside "", I foreget about that.
Gess that you have to write your own parser.
something like:

    $var = preg_replace("/_result_=/", "", $var);
    $var =trim($var);
    $var =trim($var,'{'); //remove {
    $array = explode (",", $var);
    $result=array();
    foreach ($array as $var2)
        {
        $array2=explode(':',$var2);
        $result[$array2[0]]=$array2[1];
        }  
    var_dump ($result);
pzuurveen 90 Posting Whiz in Training

This just caught my eye
line 105
if ($male == 1 && $gender = "male")
shoulden that be :
if ($male == 1 && $gender == "male")
also on line 107

paulkd commented: good catch +6
broj1 commented: Indeed +9
pzuurveen 90 Posting Whiz in Training
pzuurveen 90 Posting Whiz in Training

if both $author and $title are NULL, $result2 will be undefined.
Use isset() before using it.

pzuurveen 90 Posting Whiz in Training

$db->query returns a sqlite3result not a string.
Use $db->fetcharray to get the values

pzuurveen 90 Posting Whiz in Training

You also need a mail server. That is not normaly part of a wampp instalation.
Should be fine on your hosting server.

to install on localhost: http://flowingmotion.jojordan.org/2012/04/26/how-to-set-up-email-with-wamp/

pzuurveen 90 Posting Whiz in Training

one to many %s

$query_lignecommande = sprintf (" INSERT
INTO lignecommande(commande,article,quantite,prix,subtotal,total) VALUES (%s, %s, %s, %s, %s, %s)",
GetSQLValueString($row_commande['id'],"int"),
GetSQLValueString($row_panier['article'], "int"),
GetSQLValueString($row_panier['quantite'],"int"),
GetSQLValueString($row_panier['prix'],"double"),
GetSQLValueString($row_panier['subtotal'],"double"),
GetSQLValueString($row_panier['total'],"double"));
pzuurveen 90 Posting Whiz in Training

does your webserver has writing permision on that xml?

pzuurveen 90 Posting Whiz in Training
foreach ($array1 as $array2) 
    {
    $number[]=$array2['number'];
    }
array_multisort($number, $array1);
pzuurveen 90 Posting Whiz in Training

$pdf->Cell(0,10,'id'.$row['id'],0,1); $row['id'] don't exist : your query only gets the name.
it sould be $pdf->Output($name,I); or $pdf->Output();

header('Location: '. ".pdf"); you already send the pdf to the bouwser, also requires a full filename or url

pzuurveen 90 Posting Whiz in Training

I realy like jquery mobile for the ui
And do the database thing yourself

Szabi Zsoldos commented: also a good one +4
pzuurveen 90 Posting Whiz in Training

You never set the values of $id, $ISPID, $Aug2013 and $Sep2013
Do a var_dump($_POST), they are in there.
check out mysql_real_escape_string
also notice that mysql is deprecated and replaced by mysqli

pzuurveen 90 Posting Whiz in Training

I'm missing part of the code
checkout mysql_query and mysql_fetch_assoc

pzuurveen 90 Posting Whiz in Training

move this part to the <header> section of the calling page

  <link href="css/vertical_menu_basic.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
    <script type='text/javascript' src='js/jquery.hoverIntent.minified.js'></script>
    <script type='text/javascript' src='js/jquery.dcverticalmegamenu.1.1.js'></script>
    <script type="text/javascript">
    $(document).ready(function($){
    $('#mega-1').dcVerticalMegaMenu({
    rowItems: '3',
    speed: 'fast',
    effect: 'slide',
    direction: 'right'
    });
    });
    </script>

remove everything outside the <body> tag including the tag it self

pzuurveen 90 Posting Whiz in Training

you should parse $nfname
$copen is a file handeler, not a file name

pzuurveen 90 Posting Whiz in Training