User Profile

Collapse

Profile Sidebar

Collapse
ghjk
ghjk
Last Activity: Feb 22 '12, 07:24 AM
Joined: Jan 11 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • ghjk
    replied to Pass many variables to ajax
    in PHP
    I put the page name inside the onchange function. But It doesn't work.

    Code:
    <select name="Make"  class="normalTxt" onChange='getMakeIndexPage(this.value,index); return false; ' id="Make">
    and the ajax page
    Code:
    function getMakeIndexPage(test){
    	alert(test);
    ...
    }
    See more | Go to post

    Leave a comment:


  • ghjk
    started a topic Pass many variables to ajax
    in PHP

    Pass many variables to ajax

    I want to pass 2 variables in my php page to ajax page in onchange function. Actually this drop down box use in many pages. So I want to pass the page name to ajax page with the user selected value. How can I do that? Please help me..
    This is my code.
    Code:
    ?>
    				
    <select name="Make"  class="normalTxt" onChange='getMakeIndexPage(this.value); return false; ' id="Make" >
    <option
    ...
    See more | Go to post

  • ghjk
    replied to Pagination in php
    in PHP
    Thanx Dormilich. I solved it. But Now I'm having another problem. When I click page no 2; web banner and all other page options not displayed and only disply the pagination part. How can I solve this problem. I have searched many days and found this solution. Please help me. Now I'm really stuck. Please help me to solve this or please tell me about another working pagination tutorial..
    See more | Go to post

    Leave a comment:


  • ghjk
    replied to Dyanamic Select Query
    This is my code. When I select only vehicle type.It will get only one record. I couldn't understand where I goes wrong. Please help me..
    Code:
    if(isset($_GET['S'])==5){
    
    	$make=$_GET['make'];
    	$model=$_GET['model'];
    	$type=$_GET['type'];
    	$fuel=$_GET['fuel'];
    	$color=$_GET['color'];
    	
    
    	$query = "SELECT * FROM vehicles where";
    	if($make){
    	$query .= " vehicleMake
    ...
    See more | Go to post

    Leave a comment:


  • ghjk
    started a topic Pagination in php
    in PHP

    Pagination in php

    I want to put pagination in my search result. my code is working but got an error saying:Non-static method Pager::factory( ) should not be called statically in...
    This is my code.

    Code:
    require_once 'Pager/Pager.php';
    $sqlQuery = "select * from vehicles";
    $result = mysql_query($sqlQuery);
    $totalRows = mysql_num_rows($result);
     
    $pager_options = array(
    'mode'       => 'Sliding',
    ...
    See more | Go to post

  • ghjk
    started a topic Encrypt Password Using MD5

    Encrypt Password Using MD5

    I want to encrypt password using md5 method in javascript. This is my code and I didn't get any answer. Please help me..

    Code:
    var p = document.getElementById('Password').value;
    alert(p);// this part working
    var temp = MD5(p);
    alert(temp);//this is not working
    See more | Go to post

  • ghjk
    started a topic Dyanamic Select Query

    Dyanamic Select Query

    In my web application I'm using php and mysql. I want to create sql query to search function. There are many search fields. Sometimes user select only one field and some times two and sometimes many. How can I write that kind of query. This is my query.Other options are make, color,model,pri ce etc..

    Code:
    SELECT * FROM vehicles WHERE vehicleMake='$make' AND vehiclemodel='$model
    See more | Go to post

  • ghjk
    replied to How to insert multiple images path to database
    in PHP
    I have done it. This is the code..
    Code:
    if (isset($_POST['Submit'])) {
    	echo $_SESSION['vehicles_pk'];
        $number_of_file_fields = 0;
        $number_of_uploaded_files = 0;
        $number_of_moved_files = 0;
        $uploaded_files = array();
        $upload_directory = dirname(__file__) . '/vehicles/'; //set upload directory
        // * we get a $_FILES['images'] array ,
        // * we procee this array while
    ...
    See more | Go to post

    Leave a comment:


  • ghjk
    replied to How to insert multiple images path to database
    in PHP
    Actually I want the help of insert query. I don't know how to do that for multiple values.(one field has multiple values)
    See more | Go to post

    Leave a comment:


  • ghjk
    started a topic How to insert multiple images path to database
    in PHP

    How to insert multiple images path to database

    In my application I want to store vehicle details to mysql database. There is image field which is having more than 1 images.(select from the user) It may be 3 ,4 ,5 etc.image table has image id and image path field.When submit button click I want to add images to vehicle folder(this part working) and all images paths to the database. Really I'm wired now. I don't know how to add multiple images record to the database. Please help me. This is my...
    See more | Go to post

  • ghjk
    started a topic Can I check post and get method at once
    in PHP

    Can I check post and get method at once

    In my web page I want to check post and get method at once. This is my code. But this code is not working.."GET" recives data from ajax page and "POST" receives data from same php page.

    Code:
    if((isset($_GET['S'])==1) && (isset($_POST['Submit'])))
    echo "test";
    }
    See more | Go to post

  • ghjk
    started a topic Insert data and Images using same php form
    in PHP

    Insert data and Images using same php form

    I want to add form data and images using one form in php. I'm using php,ajax and mysql.When I run images insert code and data insert code seperately ; they worked. But when I put in the same php form data insert part doesn't work. Please tell me where I goes wrong
    This is my php page
    Code:
    [LEFT]<?php 
    session_start();
    require_once ('dbconnect.php');
    require_once ('commonFunctions.php');
    
    <script[/]
    ...
    See more | Go to post

  • ghjk
    replied to Use <div> in php page
    in PHP
    Thank you johny10151981. Your code is working. Actually In my web application 3 or more pages having same search function. But I want to display search results in one page not in own page.When user search 1st page; search results will displays on result page. 2nd page also results should be on results page. Using your code it goes to the results page . But I couldn't get results. Please help me...
    ajax code
    Code:
        function searchVehicle(){
    ...
    See more | Go to post
    Last edited by Niheel; Aug 20 '11, 08:21 PM. Reason: fixed unclosed code tag

    Leave a comment:


  • ghjk
    started a topic Use <div> in php page
    in PHP

    Use <div> in php page

    I'm using php,mysql,ajax in my web application. my index.php page has search option. I want the results to display different page(stock.php) but not in index page. When I use <div> in index page it works. But when I put div in different page it doesn't work. Where I goes wrong? Please help me..
    This is my code.
    index.php
    Code:
    <tr>[LEFT]
                  <td  height="30">&nbsp;Year&nbsp;&nbsp;&nbsp;:</td>[/]
    ...
    See more | Go to post

  • ghjk
    replied to Clear data after click on the submit button
    in PHP
    I have done it. But I don't know whether is it the correct way. But my code is working.
    Code:
    document.test.reset();
    			document.getElementById('Model').selectedIndex  = 0;
    See more | Go to post

    Leave a comment:


  • ghjk
    replied to Clear data after click on the submit button
    in PHP
    Thanx. I have Written the following code in ajx page. Then all the other fields are reset without Model field. Please tell me what is the problem with that?
    Code:
    document.test.reset();
    See more | Go to post

    Leave a comment:


  • ghjk
    replied to Add Error message in PHP
    in PHP
    ok. This is my full code.
    Code:
    [LEFT]
    if(isset($_GET['S'])==1){
    	$make=$_GET['make'];
    	getVehicleModel($make);
    	return;
    	}
    //------if user not loggerd in then set value as null------------------------------------------------
    if(!isset($_SESSION['UserName_Ses']))
    { 
    $_SESSION['UserName_Ses'] = "";
    }
    if(!isset($_SESSION['UserType_Ses'])) {
    $_SESSION['UserType_Ses'][/]
    ...
    See more | Go to post

    Leave a comment:


  • ghjk
    started a topic Clear data after click on the submit button
    in PHP

    Clear data after click on the submit button

    I' using php ,mysql and ajax. I want to add vehicles details to the database. data adding part is working. But the problem is text fields are not clear after the submit. This is my code
    Code:
    <?php 
    session_start();
    require_once ('dbconnect.php');
    require_once ('commonFunctions.php');
     ?>
    
    <script language="javascript" src="ajax.js"></script>
    </head>
    ...
    See more | Go to post

  • ghjk
    started a topic Add Error message in PHP
    in PHP

    Add Error message in PHP

    I`m using php and mysql. I want to error message in my php pages. But I want to change the message corresponding to the error. This is my code. But it is not working. Please tell me where I goes wrong?
    This is the error message depen on the error.
    Code:
    $MESSAGE = '<p class="errMsg" align="Center">Invalid Username or Password</p>'
    And this error message display on the correct...
    See more | Go to post

  • I have done it. From using the following function you can get PK of the last inserted record.

    Code:
    mysql_insert_id());
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...