Mysidia Adoptables Support Forum  

Home Community Mys-Script Creative Off-Topic
Go Back   Mysidia Adoptables Support Forum > Mysidia Adoptables > Addons and Modifications > Mys v1.2.x Mods

Notices

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #28  
Old 11-23-2011, 01:25 AM
SilverDragonTears's Avatar
SilverDragonTears SilverDragonTears is offline
I am your Nemesis.
 
Join Date: Jun 2011
Posts: 1,113
Gender: Female
Credits: 116,887
SilverDragonTears is on a distinguished road
Default

Why won't it save the sort anymore (After Maple added in a tabs feature for our adopts)?

PHP Code:
include("inc/functions.php");

//***************//
//  START SCRIPT //
//***************//

$id $_GET["id"];
$act $_GET["act"];
$more $_GET["more"];
$abilityid $_GET["abilityid"];
$tab $_GET['tab'];

if(
$isloggedin == "yes"){

if(
$act == ""){

$tabs gettabs();
$article_title .="{$loggedinname}'s Den";
        
$article_content .="


        <table width='60%' style='text-align:center;' class='shop'><center><tr><td><p class='sort' id='activate_sort'>
                         Sort Adopts - Currently NOT Working.
                    </p><center></td></tr></table></center>
        <table width='60%' style='text-align:center;' class='shop'><tr><td width='20%'><a href='trade.php'>Trade</a>-<a href='search.php'>Search</a></td>
        <td width='20%'><a href='breeding.php'>Breed</a></td>
        <td width='20%'><a href='embed.php'>Embed All</a></td>
        <td width='20%'><a href='inventory.php'>Kit Inventory</a></td><td width='20%'><a href='inventory2.php'>Adult Inventory</a></td></tr></table></center>
        <br>
         <table width='60%' style='text-align:center;' class='shop'><tr><td width='20%'><a href='tab.php'>Manage Dens</td></a>
        <td width='20%'>Select a den to go to: <select name='tab' id='tab' ONCHANGE='location = this.options[this.selectedIndex].value;'>
                                                <option value='#'>Please Select one below:</option><option value='myadopts.php'>Default</option>"
.$tabs."
                                                </select></td>
</tr></table></center>
        <br><div style='float:left;'>"
;
$query "SELECT * FROM ".$GLOBALS['prefix']."owned_collectables WHERE type = 'Halloween' AND owner = '".$loggedinname."'";
        
$result runquery($query);
    
$num mysql_numrows($result);
if(
$num 0){
$article_content .="<img src='images/candypumpkin.png' title='Trick or Treat 2011'>";
}else{
$article_content .="";
}
$query "SELECT * FROM ".$GLOBALS['prefix']."owned_adoptables WHERE type = '911 Silvfox' AND owner = '".$loggedinname."'";
        
$result runquery($query);
    
$num mysql_numrows($result);
if(
$num 0){
$article_content .="<img src='images/us.png' title='911 Event'>";
}else if(
$type == '911 Wolf'){
$article_content .="<img src='images/us.png' title='911 Event'>";
}else{
$article_content .="";
}
$query "SELECT * FROM ".$GLOBALS['prefix']."owned_adoptables LEFT JOIN ".$GLOBALS['prefix']."sort_adoptables 
                        ON "
.$GLOBALS['prefix']."owned_adoptables.aid = ".$GLOBALS['prefix']."sort_adoptables.adoptable_id WHERE owner = '".$loggedinname."' ORDER BY ".$GLOBALS['prefix']."sort_adoptables.sorting_id, ".$GLOBALS['prefix']."owned_adoptables.currentlevel ASC";
    
$result runquery($query);
    
$numpets mysql_numrows($result);

if(
$numpets >= 500){
        
$article_content .="<img src='/images/trophy-gold.png' title='Gold Trophy - Over 500 SilvAdopts'>";
} else if(
$numpets >= 200){
        
$article_content .="<img src='/images/silvertrophy.png' title='Silver Trophy - Over 200 SilvAdopts'>";
} else if(
$numpets >= 50){
        
$article_content .="<img src='/images/trophy-bronze.png' title='Bronze Trophy - Over 50 SilvAdopts'>";
}else{
        
$article_content .="";
}
$article_content .="</div><br><br>
        <br>Share this link with others to show them your Den<br>
        <input type='text' size='100' value='http://silvadopts.com/profile.php?user=
$loggedinname'><br>
        <a href='http://silvadopts.com/profile.php?user=
$loggedinname'>http://silvadopts.com/profile.php?user=$loggedinname</a><br>";

        
$article_content .= "<div style='height:100%;
        color: #fff;
    border: 1px solid #282828;
    border-top: 1px solid #363636;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px;
    padding: 5px;'><table style='width: 100%;' class='madopt' id='sortable_adoptables' ><tbody>
    <tr><th>SilvAdopt</th><th>Name</th><th>Level</th><th>Manage</th><th>Get Codes</th><th>Clicks</th></tr><br>"
;


    
// We need to get all of the user's adoptables from the database and display them...
   /* $query = "SELECT * FROM ".$prefix."owned_adoptables, ".$prefix."levels WHERE ".$prefix."owned_adoptables.owner = '{$loggedinname}'" 
    ." AND ".$prefix."owned_adoptables.type = ".$prefix."owned_adoptables.type AND ".$prefix."levels.thisislevel = ".$prefix."owned_adoptables.currentlevel AND ".$prefix."levels.adoptiename = " 
    .$prefix."owned_adoptables.type ORDER BY ".$prefix."owned_adoptables.sort, ".$prefix."owned_adoptables.totalclicks";
*/
$query "    SELECT * 
                    FROM 
{$prefix}owned_adoptables 
                    LEFT JOIN 
{$prefix}sort_adoptables 
                        ON 
{$prefix}owned_adoptables.aid = {$prefix}sort_adoptables.adoptable_id
                    INNER JOIN 
{$prefix}levels 
                        ON 
{$prefix}levels.thisislevel = {$prefix}owned_adoptables.currentlevel
                    INNER JOIN 
{$prefix}adoptables
                        ON 
{$prefix}owned_adoptables.type = {$prefix}adoptables.type
                    WHERE 
{$prefix}owned_adoptables.owner = '{$loggedinname}' AND {$prefix}owned_adoptables.tab = '{$tab}'
                    AND 
{$prefix}levels.adoptiename = {$prefix}adoptables.type
                    ORDER BY 
{$prefix}sort_adoptables.sorting_id, {$prefix}owned_adoptables.currentlevel ASC";  

    
$result runquery($query);
    
$num mysql_numrows($result);
    
//Loop out code
    
$i=0;
    while (
$i $num) {
        
$aid=@mysql_result($result,$i$prefix."owned_adoptables.aid");
        
$currentlevel=@mysql_result($result,$i$prefix."owned_adoptables.currentlevel");
        
$gender=@mysql_result($result,$i$prefix."owned_adoptables.gender");
        
$isfrozen=@mysql_result($result,$i$prefix."owned_adoptables.isfrozen");
        
$type=@mysql_result($result,$i$prefix."owned_adoptables.type");
        
$name=@mysql_result($result,$i$prefix."owned_adoptables.name");
        
$eggimage=@mysql_result($result,$i$prefix."adoptables.eggimage");
        
$usealternates=@mysql_result($result,$i$prefix."owned_adoptables.usealternates");
        
$totalclicks=@mysql_result($result,$i$prefix."owned_adoptables.totalclicks");
        
$primaryimage=@mysql_result($result,$i$prefix."levels.primaryimage");
        
$alternateimage=@mysql_result($result,$i$prefix."levels.alternateimage");
        if (
$usealternates=='yes') { $image $alternateimage; }
        else { 
$image $primaryimage; }
        if (
$currentlevel==0) { $image $eggimage; }
        if (
$image=='') { $image $primaryimage; }
    
$article_content .= "<tr id='orderaid_{$aid}'><td width='20%'><a href='myadopts.php?act=stats&id=".$aid."'><img src='$image'></a></td><td width='20%'>";

if(
$isfrozen == 'no') {
    
$article_content .= '';
} else {
    
$article_content .= '<img src=\'images/snowflake.png\'>';
    

__________________

Check out SilvaTales
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
"Fairy State" theme by Bobbybighoof (Mysidia 1.3.3) bobbybig Templates and Themes 3 07-18-2018 06:54 PM
Sort "myadopts" page SilverDragonTears Questions and Supports 23 06-12-2017 05:39 PM
Removing of prefix "class", "abstract", "interface" Suggestions FounderSim Suggestions and Feature Requests 3 10-05-2014 05:35 PM
Creating a "Faction" for adoptables/owned adoptables Vaporman87 Questions and Supports 1 03-04-2014 03:38 PM
Changing... or "masking" existing URLs Vaporman87 Questions and Supports 7 03-03-2014 07:10 PM


All times are GMT -5. The time now is 10:03 AM.

Currently Active Users: 2587 (0 members and 2587 guests)
Threads: 4,081, Posts: 32,032, Members: 2,016
Welcome to our newest members, jolob.
BETA





What's New?

What's Hot?

What's Popular?


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
vBCommerce I v2.0.0 Gold ©2010, PixelFX Studios
vBCredits I v2.0.0 Gold ©2010, PixelFX Studios
Emoticons by darkmoon3636