shop with page

Results 1 to 9 of 9
  1. #1
    Valued Member Alkyron is offline
    MemberRank
    Jun 2007 Join Date
    100Posts

    shop with page

    How to make a shop with pages?

    Example :

    http://systemgames.no-ip.biz/gunz/index.php?do=cashshop⊂=listallitems&expand=1&page=1

    Please need help .


  2. #2
    Account Upgraded | Title Enabled! sayuta is offline
    MemberRank
    Jan 2007 Join Date
    The NetherlandsLocation
    205Posts

    Re: shop with page

    Edit the limit?

    Like

    PHP Code:
    $page $_GET['page'];
    $limit '5';
    $new $limit $page;
    $new2 $new $limit
    $query 
    mssql_query("SELECT * FROM items WHERE inshop = '1' DESC LIMIT $new2,$new"); 
    Somthing like that >_>"..

    $page = Get Page id,
    $limit = howmuch items per page.
    $new2 = starting offset (if $page = 1, starting offset = ((1*5)-5) = 0)
    $new = end offset (if $page = 1, starting offset = (1*5) = 5)

    Ex. if Page2.
    $new2 = ((2*5)-5) = 5
    $new = (2*5) = 10

    So it will take the items in that gap

  3. #3
    Valued Member Alkyron is offline
    MemberRank
    Jun 2007 Join Date
    100Posts

    Re: shop with page

    Wow nice i go edit !

  4. #4
    Valued Member Alkyron is offline
    MemberRank
    Jun 2007 Join Date
    100Posts

    Re: shop with page

    Quote Originally Posted by sayuta View Post
    Edit the limit?

    Like

    PHP Code:
    $page $_GET['page'];
    $limit '5';
    $new $limit $page;
    $new2 $new $limit
    $query 
    mssql_query("SELECT * FROM items WHERE inshop = '1' DESC LIMIT $new2,$new"); 
    Somthing like that >_>"..

    $page = Get Page id,
    $limit = howmuch items per page.
    $new2 = starting offset (if $page = 1, starting offset = ((1*5)-5) = 0)
    $new = end offset (if $page = 1, starting offset = (1*5) = 5)

    Ex. if Page2.
    $new2 = ((2*5)-5) = 5
    $new = (2*5) = 10

    So it will take the items in that gap
    Not work . . .

  5. #5
    DRGunZ 2 Creator wesman2232 is offline
    MemberRank
    Jan 2007 Join Date
    Erie, PALocation
    4,872Posts

    Re: shop with page

    cause LIMIT only works in MySQL

  6. #6
    Valued Member Alkyron is offline
    MemberRank
    Jun 2007 Join Date
    100Posts

    Re: shop with page

    Help me please

  7. #7
    2D > 3D Wucas is offline
    MemberRank
    Dec 2008 Join Date
    In your bed :3Location
    2,523Posts

    Re: shop with page

    Quote Originally Posted by wesman2232 View Post
    cause LIMIT only works in MySQL
    i like mysql so much more then mssql really <.<

  8. #8
    Account Upgraded | Title Enabled! alfredao is offline
    MemberRank
    Jan 2008 Join Date
    Coronel FabriciLocation
    705Posts

  9. #9
    Valued Member Alkyron is offline
    MemberRank
    Jun 2007 Join Date
    100Posts

    Re: shop with page

    Translate please ?



Advertisement