Can't add items to website shop!!!

Results 1 to 11 of 11
  1. #1
    num num num <3 rootbeer daniel131605 is offline
    MemberRank
    Jul 2008 Join Date
    New YorkLocation
    573Posts

    sad Can't add items to website shop!!!

    i can't add donator items to the item shop on my website can someone help please? im using the b2o website and when i put all the correct info in it says added correctly but under it it has a bunch of errors
    Attached Thumbnails Attached Thumbnails apples.jpg  


  2. #2
    Currently Stoned ! Ronny786 is offline
    MemberRank
    Dec 2011 Join Date
    Lost WorldLocation
    984Posts

    Re: Can't add items to website shop!!!

    Some columns are missing in your Database table...

    I think u formatted ur dbo.item columns.

    Read errors carefully :

    Invalid Column name CSSID : It means your table doesnt contain 'CSSID' column.

    Solution:

    Go to GunzDB> Right Click 'dbo.item' table > press 'Modify' > and then add missing columns(at bottom of columns).

    Do this to all missing columns . " Name, Description,ResLevel, etc etc "

    Good Luck!

  3. #3
    num num num <3 rootbeer daniel131605 is offline
    MemberRank
    Jul 2008 Join Date
    New YorkLocation
    573Posts

    Re: Can't add items to website shop!!!

    Quote Originally Posted by Ronny786 View Post
    Some columns are missing in your Database table...

    I think u formatted ur dbo.item columns.

    Read errors carefully :

    Invalid Column name CSSID : It means your table doesnt contain 'CSSID' column.

    Solution:

    Go to GunzDB> Right Click 'dbo.item' table > press 'Modify' > and then add missing columns(at bottom of columns).

    Do this to all missing columns . " Name, Description,ResLevel, etc etc "

    Good Luck!


    thanks! when i add them what thing do i set them as? tinynt or whatever?

  4. #4
    Currently Stoned ! Ronny786 is offline
    MemberRank
    Dec 2011 Join Date
    Lost WorldLocation
    984Posts

    Re: Can't add items to website shop!!!

    Did my post helped? :P

  5. #5
    Account Upgraded | Title Enabled! BG-Nero is offline
    MemberRank
    Feb 2012 Join Date
    GermanyLocation
    285Posts

    Re: Can't add items to website shop!!!

    Quote Originally Posted by daniel131605 View Post
    thanks! when i add them what thing do i set them as? tinynt or whatever?
    Reslevel , Damage , Delay the important things of the weapon

  6. #6
    num num num <3 rootbeer daniel131605 is offline
    MemberRank
    Jul 2008 Join Date
    New YorkLocation
    573Posts

    Re: Can't add items to website shop!!!

    i fixed it by myself lol i figured it out, but i have another question

    Code:
                }
                mssql_query("INSERT INTO AccountItem ([ShopItemID], [AID], [ItemID], [RentDate], [RentHourPeriod], 
    
    [Cnt],[Quantity])VALUES('$itemid', '$aid', '$itemid', GETDATE(), 168, 0,1)");
                mssql_query("UPDATE CashShop SET Selled = Selled + 1 WHERE CSID = $itemid");
                mssql_query("UPDATE Login SET euCoins = '$updatecoins' WHERE AID = '$aid'");
                msgbox("Item purchased correctly, you will be introduced in Storage","index.php?
    
    do=itemshop&sub=listallitems&expand=1&type=3");
           }
           ?>
    what is in red is what i need, i need a code to put the right item id into that spot, it keeps putting 0 in it and not the right item id so when you go to dbo.accountitem the item id is 0 and i need it to be 20010 (the donation item) im not sure what code to put there to make it find the right number that i need, so i buy the item from the donation shop, and it puts the info into the database, but it says that there is no name for the weapon unless i go into the database and go to dbo.accountitem and change the id from 0 to 20010, so i need a $ code do put there to find the right itemID for this item and not just put 0, thanks

  7. #7
    Hi, I'm Omar! Vusion is offline
    MemberRank
    Jan 2011 Join Date
    HereLocation
    1,658Posts

    Re: Can't add items to website shop!!!

    What's the value of $itemid? Try searching for something such as "$itemid ="
    Posted via Mobile Device

  8. #8
    Member iDelta is offline
    MemberRank
    Mar 2012 Join Date
    67Posts

    Re: Can't add items to website shop!!!

    Didn't you have to execute some SQL's to your database?

  9. #9
    num num num <3 rootbeer daniel131605 is offline
    MemberRank
    Jul 2008 Join Date
    New YorkLocation
    573Posts

    Re: Can't add items to website shop!!!

    Quote Originally Posted by Vusion View Post
    What's the value of $itemid? Try searching for something such as "$itemid ="
    Posted via Mobile Device


    if(!function_exists("ShowItemsDetails")){
    function ShowItemsDetails(){
    if($_GET['id'] == ""){
    re_dir("index.php");
    }
    $itemid = antisql($_GET['id']);
    $res = mssql_query("SELECT * FROM CashShop WHERE CSID = '$itemid'");
    $item = mssql_fetch_assoc($res);
    if($item['ForSale'] > 0){
    msgbox("You cant buy this","index.php?do=itemshop&sub=listallitems&expand=1&type=3");
    die("You cant buy this");
    }



    //And another one.
    $res2 = mssql_query("SELECT euCoins FROM Login WHERE AID = '" . antisql($_SESSION['AID']) . "'");
    $acc = mssql_fetch_assoc($res2);
    if(isset($_POST['submit'])){
    $itemid = antisql($_POST['ItemID']);
    $res = mssql_query("SELECT * FROM CashShop WHERE CSID = '$itemid'");
    $item = mssql_fetch_assoc($res);
    if($item['ForSale'] > 0){
    msgbox("You cant buy this","index.php?do=itemshop&sub=listallitems&expand=1&type=3");
    die("You cant buy this");
    }


    those are the 2 i have in there dealing with that, but im pretty sure i looked at that stuff before looking to make it look for the itemid that i put in when i create the weapon with the Add Item to Shop button




    Quote Originally Posted by iDelta View Post
    Didn't you have to execute some SQL's to your database?
    yeah i already did that when i first started working on the site, and the sql i used didn't work all the way so ive been editing the stuff where i get erros...

    if(!function_exists("ShowItemsDetails")){
    function ShowItemsDetails(){
    if($_GET['id'] == ""){
    re_dir("index.php");
    }
    $itemid1 = antisql($_GET['id']);
    $res = mssql_query("SELECT * FROM CashShop WHERE CSSID = '$itemid1'");
    $item1 = mssql_fetch_assoc($res);
    if($item['ForSale'] > 0){
    msgbox("You cant buy this","index.php?do=itemshop&sub=listallitems&expand=1&type=3");
    die("You cant buy this");
    }


    will this work? add this to my php script then changed the 2 $itemid to having 1 $itemid and the other one that keeps messing up to be $itemid1 (because its looking for CSSID which should be the correct number )

  10. #10
    Proficient Member Drkidvictor is offline
    MemberRank
    Jul 2011 Join Date
    New JerseyLocation
    174Posts

    Re: Can't add items to website shop!!!

    What web are you using? Seems like it has Errors o.o

  11. #11
    num num num <3 rootbeer daniel131605 is offline
    MemberRank
    Jul 2008 Join Date
    New YorkLocation
    573Posts

    Re: Can't add items to website shop!!!

    well yeah... it wasn't finished all the way, its b2o and i tried what i said at the end and it didn't work



Advertisement