Mysidia Adoptables Support Forum  

Home Community Mys-Script Creative Off-Topic
Go Back   Mysidia Adoptables Support Forum > Mysidia Adoptables > Questions and Supports

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 04-24-2017, 01:37 PM
aquapyrofan aquapyrofan is offline
Member
 
Join Date: Apr 2017
Posts: 48
Gender: Unknown/Other
Credits: 8,386
aquapyrofan is on a distinguished road
Question Add Favorite Adopt to sidebar?

I'm wanting to add the user's favorite adopt to a sidebar module with the following structure:

(Image)
Name the Species
View | Change

The view link would go to either their profile (if I can set that up) or to their "manage" page, while the "change" link would go to change the "active pet." Potentially with icons, most likely not.

How would I go about this?
Reply With Quote
  #2  
Old 04-24-2017, 02:32 PM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 113,095
Abronsyth is on a distinguished road
Default

You'll want to check out this thread;
http://mysidiaadoptables.com/forum/s...favpet+sidebar
__________________
My Mods Site (1.3.4, 2020 Mods)
Reply With Quote
  #3  
Old 04-24-2017, 08:04 PM
aquapyrofan aquapyrofan is offline
Member
 
Join Date: Apr 2017
Posts: 48
Gender: Unknown/Other
Credits: 8,386
aquapyrofan is on a distinguished road
Default

Quote:
Originally Posted by Abronsyth View Post
You'll want to check out this thread;
http://mysidiaadoptables.com/forum/s...favpet+sidebar
That didn't actually help because I don't actually want anything in there aside from the name, species, image, and links to view or change the active, and I still don't know how to fetch and display that information (or in the case of the links, how to do them at all in there).
Reply With Quote
  #4  
Old 04-24-2017, 09:03 PM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 87,984
Kyttias is on a distinguished road
Default

I know that thread is a lot to follow through, but I helped them with the basics before moving on. Here it is with just what you wanted:

To make a favpet display in the sidebar, first in the AdminCP you'll create a module (surprisingly not a widget):


Then in classes/class_sidebar.php you'll need to add these functions:

PHP Code:
public function getFavPetSB(){
    return 
$this->FavPetSB;
}

protected function 
setFavPetSB(){
    
$mysidia Registry::get("mysidia");
    
$profile $mysidia->user->getprofile();
    
    if (
$profile->getFavpetID() == "0"){ // In case the user's fav pet isn't set...
        
$this->FavPetSB = new Paragraph
        
$this->FavPetSB->add(new Comment("

            <br>
            <b>No Favorite Pet!</b>
            <br>
            <a href='
{$mysidia->path->getAbsolute()}account/activepet'>Choose Favorite Pet?</a>

        "
));
    } else { 
// It must be set, so let's pull information from it.
        
$favpet = new OwnedAdoptable($profile->getFavpetID());
        
$this->FavPetSB = new Paragraph;
            
$this->FavPetSB->add(new Comment("

            <br>    
            <img src='
{$favpet->getImage()}'>
            <br>
            
{$favpet->getName()} the {$favpet->getType()}
            <br>
            <a href='
{$mysidia->path->getAbsolute()}myadopts/manage/{$favpet->getAdoptID()}'>View</a> | <a href='{$mysidia->path->getAbsolute()}account/activepet'>Change</a>

        "
));
    }

Try that and let me know how it goes? For some clarification, if it helps--

$mysidia = Registry::get("mysidia"); // $mysidia is like god

$profile = $mysidia->user->getprofile(); // $mysidia->user is an instance of the member class, so the function getprofile() is actually being called from class_member.php -- and what getprofile() does is create a new instance of the class_userprofile, which basically pulls information about (the current) user from the database

$profile->getFavpetID() // so now our variable $profile is calling getFavpetID() from, you guessed it, class_userprofile.php, to get the id of the favorite pet (from here we check whether or not its set to anything past the default value of 0 and then move on)

$favpet = new OwnedAdoptable($profile->getFavpetID()); // now we're creating $favpet as a new instance of the class "OwnedAdoptable" so we can call up functions from class_ownedadoptable.php and use them - but create a new instance of this class requires a parameter, and in this case, what it wants is the adoptable's ID number, so, that's exactly what we feed it

$favpet->getImage() and $favpet->getName() and $favpet->getType() // these are all functions found in class_ownedadoptable.php -- so definitely check out that file to see what other kind of information you can dig up -- in addition, 'public' variables set at the top are also immediately accessible without a function call

$mysidia->path->getAbsolute() // this one's really handy - $mysidia knows exactly what the root of your url is from when you installed, so you never have to worry if you change hosts or whatever - here we're using it to make sure our links definitely go to the right place every single time
__________________
Please do not contact me directly outside of Mysidia.
I also cannot troubleshoot code more than two years old - I legit don't remember it.

Last edited by Kyttias; 04-24-2017 at 09:45 PM.
Reply With Quote
  #5  
Old 04-24-2017, 09:31 PM
aquapyrofan aquapyrofan is offline
Member
 
Join Date: Apr 2017
Posts: 48
Gender: Unknown/Other
Credits: 8,386
aquapyrofan is on a distinguished road
Default

Quote:
Originally Posted by Kyttias View Post
I know that thread is a lot to follow through, but I helped them with the basics before moving on. Here it is with just what you wanted:

To make a favpet display in the sidebar, first in the AdminCP you'll create a module (surprisingly not a widget):


Then in classes/class_sidebar.php you'll need to add these functions:

PHP Code:
public function getFavPetSB(){
    return 
$this->FavPetSB;
}

protected function 
setFavPetSB(){
    
$mysidia Registry::get("mysidia");
    
$profile $mysidia->user->getprofile();
    
    if (
$profile->getFavpetID() == "0"){ // In case the user's fav pet isn't set...
        
$this->FavPetSB = new Paragraph
        
$this->FavPetSB->add(new Comment("

            <br>
            <b>No Favorite Pet!</b>
            <br>
            <a href='
{$mysidia->path->getAbsolute()}account/activepet'>Choose Favorite Pet?</a>

        "
));
    } else { 
// It must be set, so let's pull information from it.
        
$favpet = new OwnedAdoptable($profile->getFavpetID());

        
$this->FavPetSB->add(new Comment("

            <br>    
            <img src='
{$favpet->getImage()}'>
            <br>
            
{$favpet->getName()} the {$favpet->getType()}
            <br>
            <a href='
{$mysidia->path->getAbsolute()}myadopts/manage/{$favpet->getAdoptID()}'>View</a> | <a href='{$mysidia->path->getAbsolute()}account/activepet'>Change</a>

        "
));
    }

Try that and let me know how it goes? For some clarification, if it helps--

$mysidia = Registry::get("mysidia"); // $mysidia is like god

$profile = $mysidia->user->getprofile(); // $mysidia->user is an instance of the member class, so the function getprofile() is actually being called from class_member.php -- and what getprofile() does is create a new instance of the class_userprofile, which basically pulls information about (the current) user from the database

$profile->getFavpetID() // so now our variable $profile is calling getFavpetID() from, you guessed it, class_userprofile.php, to get the id of the favorite pet (from here we check whether or not its set to anything past the default value of 0 and then move on)

$favpet = new OwnedAdoptable($profile->getFavpetID()); // now we're creating $favpet as a new instance of the class "OwnedAdoptable" so we can call up functions from class_ownedadoptable.php and use them - but create a new instance of this class requires a parameter, and in this case, what it wants is the adoptable's ID number, so, that's exactly what we feed it

$favpet->getImage() and $favpet->getName() and $favpet->getType() // these are all functions found in class_ownedadoptable.php -- so definitely check out that file to see what other kind of information you can dig up -- in addition, 'public' variables set at the top are also immediately accessible without a function call

$mysidia->path->getAbsolute() // this one's really handy - $mysidia knows exactly what the root of your url is from when you installed, so you never have to worry if you change hosts or whatever - here we're using it to make sure our links definitely go to the right place every single time
Where exactly am I supposed to put that? I get a HTTP ERROR 500 so I know something isn't right.
Reply With Quote
  #6  
Old 04-24-2017, 09:46 PM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 87,984
Kyttias is on a distinguished road
Default

Here, replace your entire classes/class_sidebar.php file with this one:
PHP Code:
<?php

/**
 * The Sidebar Class, defines a standard HTML Sidebar component.
 * It extends from the Widget class, while adding its own implementation.
 * @category Resource
 * @package Widget
 * @author Hall of Famer 
 * @copyright Mysidia Adoptables Script
 * @link http://www.mysidiaadoptables.com
 * @since 1.3.3
 * @todo Not much at this point.
 *
 */

class Sidebar extends Widget{

    
/**
     * The moneyBar property, specifies the money/donation bar for members.
     * @access protected
     * @var Paragraph
    */
    
protected $moneyBar;
    
    
/**
     * The linksBar property, stores all useful links for members.
     * @access protected
     * @var Paragraph
    */
    
protected $linksBar;
    
    
/**
     * The wolBar property, determines the who's online url in the sidebar.
     * @access protected
     * @var Link
    */
    
protected $wolBar;
    
    
/**
     * The loginBar property, specifies the loginBar for guests.
     * @access protected
     * @var FormBuilder
    */
    
protected $loginBar;

    
/**
     * Constructor of Sidebar Class, it initializes basic sidebar properties     
     * @access public
     * @return Void
     */
    
public function __construct(){
        
parent::__construct(4"sidebar");
    }
    
    
/**
     * The setDivision method, setter method for property $division.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @param GUIComponent  $module
     * @access protected
     * @return Void
     */
    
protected function setDivision(GUIComponent $module){
        if(!
$this->division){
            
$this->division = new Division;
            
$this->division->setClass("sidebar");
        }   
        
$this->division->add($module);
    }


    
    
//////////////////////////////////////////////////////////////////////////////////
    //////////////////////////////////////////////////////////////////////////////////
    /// From: http://www.mysidiaadoptables.com/forum/showthread.php?t=5419
    /// 
    
public function getFavPetSB(){
        return 
$this->FavPetSB;
    }

    protected function 
setFavPetSB(){
        
$mysidia Registry::get("mysidia");
        
$profile $mysidia->user->getprofile();
        
        if (
$profile->getFavpetID() == "0"){ // In case the user's fav pet isn't set...
            
$this->FavPetSB = new Paragraph
            
$this->FavPetSB->add(new Comment("

                <br>
                <b>No Favorite Pet!</b>
                <br>
                <a href='
{$mysidia->path->getAbsolute()}account/activepet'>Choose Favorite Pet?</a>

            "
));
        } else { 
// It must be set, so let's pull information from it.
            
$favpet = new OwnedAdoptable($profile->getFavpetID());
            
$this->FavPetSB = new Paragraph;
            
$this->FavPetSB->add(new Comment("

                <br>    
                <img src='
{$favpet->getImage()}'>
                <br>
                
{$favpet->getName()} the {$favpet->getType()}
                <br>
                <a href='
{$mysidia->path->getAbsolute()}myadopts/manage/{$favpet->getAdoptID()}'>View</a> | <a href='{$mysidia->path->getAbsolute()}account/activepet'>Change</a>

            "
));
        }
    }  
    
///
    ///
    //////////////////////////////////////////////////////////////////////////////////
    //////////////////////////////////////////////////////////////////////////////////
    
    
    /**
     * The getMoneyBar method, getter method for property $moneyBar.
     * @access public
     * @return Paragraph
     */
    
public function getMoneyBar(){
        return 
$this->moneyBar;
    }

    
    
/**
     * The setMoneyBar method, setter method for property $moneyBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setMoneyBar(){
        
$mysidia Registry::get("mysidia");
        
$this->moneyBar = new Paragraph;
        
$this->moneyBar->add(new Comment("You have {$mysidia->user->money} {$mysidia->settings->cost}."));
        
        
$donate = new Link("donate");
        
$donate->setText("Donate Money to Friends");
        
$this->moneyBar->add($donate);
        
$this->setDivision($this->moneyBar);        
    }

    
/**
     * The getLinksBar method, getter method for property $linksBar.
     * @access public
     * @return Paragraph
     */
    
public function getLinksBar(){
        return 
$this->linksBar;
    }
    
    
/**
     * The setLinksBar method, setter method for property $linksBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLinksBar(){
        
$mysidia Registry::get("mysidia");
        
$this->linksBar = new Paragraph;
        
$linkTitle = new Comment("{$mysidia->user->username}'s Links:");
        
$linkTitle->setBold();
        
$this->linksBar->add($linkTitle);
        
        
$linksList = new LinksList("ul");
        
$this->setLinks($linksList);
        
        
$this->linksBar->add($linksList);
        
$this->setDivision($this->linksBar);    
    }

    
/**
     * The setLinks method, append all links to the LinksBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLinks(LinksList $linksList){
        
$mysidia Registry::get("mysidia");
        
$stmt $mysidia->db->select("links", array("id""linktext""linkurl"), "linktype = 'sidelink' ORDER BY linkorder");
        if(
$stmt->rowCount() == 0) Throw new Exception("There is an error with sidebar links, please contact the admin immediately for help.");
        
        while(
$sideLink $stmt->fetchObject()){
            
$link = new Link($sideLink->linkurl);
            
$link->setText($sideLink->linktext);
            if(
$sideLink->linkurl == "messages"){
                
$num $mysidia->db->select("messages", array("touser"), "touser='{$mysidia->user->username}' and status='unread'")->rowCount();
                if(
$num 0$link->setText("<b>{$link->getText()} ({$num})</b>");
            }
            
$link->setListed(TRUE);
            
$linksList->add($link);   
        }
        
        if(
$mysidia->user instanceof Admin){
            
$adminCP = new Link("admincp/"FALSEFALSE);
            
$adminCP->setText("Admin Control Panel");
            
$adminCP->setListed(TRUE);  
            
$linksList->add($adminCP);          
        }
    }
    
    
/**
     * The getWolBar method, getter method for property $wolBar.
     * @access public
     * @return LinksList
     */
    
public function getWolBar(){
        return 
$this->wolBar;
    }
    
    
/**
     * The setWolBar method, setter method for property $wolBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setWolBar(){
        
$mysidia Registry::get("mysidia");
        
$this->wolBar = new Link("online");
        
$online $mysidia->db->select("online", array(), "username != 'Visitor'")->rowCount();
        
$offline $mysidia->db->select("online", array(), "username = 'Visitor'")->rowCount();
        
$this->wolBar->setText("This site has {$online} members and {$offline} guests online.");
        
$this->setDivision($this->wolBar);      
    }
    
    
/**
     * The getLoginBar method, getter method for property $loginBar.
     * @access public
     * @return FormBuilder
     */
    
public function getLoginBar(){
        return 
$this->loginBar;
    }
    
    
/**
     * The setLoginBar method, setter method for property $loginBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLoginBar(){
        
$this->loginBar = new FormBuilder("login""login""post");
        
$loginTitle = new Comment("Member Login:");
        
$loginTitle->setBold();
        
$loginTitle->setUnderlined();
        
$this->loginBar->add($loginTitle);

        
$this->loginBar->buildComment("username: "FALSE)
                       ->
buildTextField("username")
                       ->
buildComment("password: "FALSE)
                       ->
buildPasswordField("password""password"""TRUE)   
                       ->
buildButton("Log In""submit""submit")
                       ->
buildComment("Don't have an account?"); 
                       
        
$register = new Link("register");
        
$register->setText("Register New Account");
        
$register->setLineBreak(TRUE);
        
$forgot = new Link("forgotpass");
        
$forgot->setText("Forgot Password?");
        
        
$this->loginBar->add($register);
        
$this->loginBar->add($forgot);
        
$this->setDivision($this->loginBar);    
    }
}
?>
__________________
Please do not contact me directly outside of Mysidia.
I also cannot troubleshoot code more than two years old - I legit don't remember it.
Reply With Quote
  #7  
Old 04-24-2017, 09:55 PM
aquapyrofan aquapyrofan is offline
Member
 
Join Date: Apr 2017
Posts: 48
Gender: Unknown/Other
Credits: 8,386
aquapyrofan is on a distinguished road
Default

Quote:
Originally Posted by Kyttias View Post
Here, replace your entire classes/class_sidebar.php file with this one:
PHP Code:
<?php

/**
 * The Sidebar Class, defines a standard HTML Sidebar component.
 * It extends from the Widget class, while adding its own implementation.
 * @category Resource
 * @package Widget
 * @author Hall of Famer 
 * @copyright Mysidia Adoptables Script
 * @link http://www.mysidiaadoptables.com
 * @since 1.3.3
 * @todo Not much at this point.
 *
 */

class Sidebar extends Widget{

    
/**
     * The moneyBar property, specifies the money/donation bar for members.
     * @access protected
     * @var Paragraph
    */
    
protected $moneyBar;
    
    
/**
     * The linksBar property, stores all useful links for members.
     * @access protected
     * @var Paragraph
    */
    
protected $linksBar;
    
    
/**
     * The wolBar property, determines the who's online url in the sidebar.
     * @access protected
     * @var Link
    */
    
protected $wolBar;
    
    
/**
     * The loginBar property, specifies the loginBar for guests.
     * @access protected
     * @var FormBuilder
    */
    
protected $loginBar;

    
/**
     * Constructor of Sidebar Class, it initializes basic sidebar properties     
     * @access public
     * @return Void
     */
    
public function __construct(){
        
parent::__construct(4"sidebar");
    }
    
    
/**
     * The setDivision method, setter method for property $division.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @param GUIComponent  $module
     * @access protected
     * @return Void
     */
    
protected function setDivision(GUIComponent $module){
        if(!
$this->division){
            
$this->division = new Division;
            
$this->division->setClass("sidebar");
        }   
        
$this->division->add($module);
    }


    
    
//////////////////////////////////////////////////////////////////////////////////
    //////////////////////////////////////////////////////////////////////////////////
    /// From: http://www.mysidiaadoptables.com/forum/showthread.php?t=5419
    /// 
    
public function getFavPetSB(){
        return 
$this->FavPetSB;
    }

    protected function 
setFavPetSB(){
        
$mysidia Registry::get("mysidia");
        
$profile $mysidia->user->getprofile();
        
        if (
$profile->getFavpetID() == "0"){ // In case the user's fav pet isn't set...
            
$this->FavPetSB = new Paragraph
            
$this->FavPetSB->add(new Comment("

                <br>
                <b>No Favorite Pet!</b>
                <br>
                <a href='
{$mysidia->path->getAbsolute()}account/activepet'>Choose Favorite Pet?</a>

            "
));
        } else { 
// It must be set, so let's pull information from it.
            
$favpet = new OwnedAdoptable($profile->getFavpetID());
            
$this->FavPetSB = new Paragraph;
            
$this->FavPetSB->add(new Comment("

                <br>    
                <img src='
{$favpet->getImage()}'>
                <br>
                
{$favpet->getName()} the {$favpet->getType()}
                <br>
                <a href='
{$mysidia->path->getAbsolute()}myadopts/manage/{$favpet->getAdoptID()}'>View</a> | <a href='{$mysidia->path->getAbsolute()}account/activepet'>Change</a>

            "
));
        }
    }  
    
///
    ///
    //////////////////////////////////////////////////////////////////////////////////
    //////////////////////////////////////////////////////////////////////////////////
    
    
    /**
     * The getMoneyBar method, getter method for property $moneyBar.
     * @access public
     * @return Paragraph
     */
    
public function getMoneyBar(){
        return 
$this->moneyBar;
    }

    
    
/**
     * The setMoneyBar method, setter method for property $moneyBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setMoneyBar(){
        
$mysidia Registry::get("mysidia");
        
$this->moneyBar = new Paragraph;
        
$this->moneyBar->add(new Comment("You have {$mysidia->user->money} {$mysidia->settings->cost}."));
        
        
$donate = new Link("donate");
        
$donate->setText("Donate Money to Friends");
        
$this->moneyBar->add($donate);
        
$this->setDivision($this->moneyBar);        
    }

    
/**
     * The getLinksBar method, getter method for property $linksBar.
     * @access public
     * @return Paragraph
     */
    
public function getLinksBar(){
        return 
$this->linksBar;
    }
    
    
/**
     * The setLinksBar method, setter method for property $linksBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLinksBar(){
        
$mysidia Registry::get("mysidia");
        
$this->linksBar = new Paragraph;
        
$linkTitle = new Comment("{$mysidia->user->username}'s Links:");
        
$linkTitle->setBold();
        
$this->linksBar->add($linkTitle);
        
        
$linksList = new LinksList("ul");
        
$this->setLinks($linksList);
        
        
$this->linksBar->add($linksList);
        
$this->setDivision($this->linksBar);    
    }

    
/**
     * The setLinks method, append all links to the LinksBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLinks(LinksList $linksList){
        
$mysidia Registry::get("mysidia");
        
$stmt $mysidia->db->select("links", array("id""linktext""linkurl"), "linktype = 'sidelink' ORDER BY linkorder");
        if(
$stmt->rowCount() == 0) Throw new Exception("There is an error with sidebar links, please contact the admin immediately for help.");
        
        while(
$sideLink $stmt->fetchObject()){
            
$link = new Link($sideLink->linkurl);
            
$link->setText($sideLink->linktext);
            if(
$sideLink->linkurl == "messages"){
                
$num $mysidia->db->select("messages", array("touser"), "touser='{$mysidia->user->username}' and status='unread'")->rowCount();
                if(
$num 0$link->setText("<b>{$link->getText()} ({$num})</b>");
            }
            
$link->setListed(TRUE);
            
$linksList->add($link);   
        }
        
        if(
$mysidia->user instanceof Admin){
            
$adminCP = new Link("admincp/"FALSEFALSE);
            
$adminCP->setText("Admin Control Panel");
            
$adminCP->setListed(TRUE);  
            
$linksList->add($adminCP);          
        }
    }
    
    
/**
     * The getWolBar method, getter method for property $wolBar.
     * @access public
     * @return LinksList
     */
    
public function getWolBar(){
        return 
$this->wolBar;
    }
    
    
/**
     * The setWolBar method, setter method for property $wolBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setWolBar(){
        
$mysidia Registry::get("mysidia");
        
$this->wolBar = new Link("online");
        
$online $mysidia->db->select("online", array(), "username != 'Visitor'")->rowCount();
        
$offline $mysidia->db->select("online", array(), "username = 'Visitor'")->rowCount();
        
$this->wolBar->setText("This site has {$online} members and {$offline} guests online.");
        
$this->setDivision($this->wolBar);      
    }
    
    
/**
     * The getLoginBar method, getter method for property $loginBar.
     * @access public
     * @return FormBuilder
     */
    
public function getLoginBar(){
        return 
$this->loginBar;
    }
    
    
/**
     * The setLoginBar method, setter method for property $loginBar.
     * It is set internally upon object instantiation, cannot be accessed in client code.
     * @access protected
     * @return Void
     */
    
protected function setLoginBar(){
        
$this->loginBar = new FormBuilder("login""login""post");
        
$loginTitle = new Comment("Member Login:");
        
$loginTitle->setBold();
        
$loginTitle->setUnderlined();
        
$this->loginBar->add($loginTitle);

        
$this->loginBar->buildComment("username: "FALSE)
                       ->
buildTextField("username")
                       ->
buildComment("password: "FALSE)
                       ->
buildPasswordField("password""password"""TRUE)   
                       ->
buildButton("Log In""submit""submit")
                       ->
buildComment("Don't have an account?"); 
                       
        
$register = new Link("register");
        
$register->setText("Register New Account");
        
$register->setLineBreak(TRUE);
        
$forgot = new Link("forgotpass");
        
$forgot->setText("Forgot Password?");
        
        
$this->loginBar->add($register);
        
$this->loginBar->add($forgot);
        
$this->setDivision($this->loginBar);    
    }
}
?>
Well, it's not throwing an error this time, but nothing's showing up in the sidebar.
Reply With Quote
  #8  
Old 04-24-2017, 10:19 PM
Kyttias's Avatar
Kyttias Kyttias is offline
Premium Member
 
Join Date: Jan 2014
Posts: 857
Gender: Unknown/Other
Credits: 87,984
Kyttias is on a distinguished road
Default

I tested this exact version of the file on my own site and it works just fine? Are you sure you created the module in the Admin CP exactly how the image shows?
__________________
Please do not contact me directly outside of Mysidia.
I also cannot troubleshoot code more than two years old - I legit don't remember it.
Reply With Quote
  #9  
Old 04-24-2017, 10:30 PM
aquapyrofan aquapyrofan is offline
Member
 
Join Date: Apr 2017
Posts: 48
Gender: Unknown/Other
Credits: 8,386
aquapyrofan is on a distinguished road
Default

Quote:
Originally Posted by Kyttias View Post
I tested this exact version of the file on my own site and it works just fine? Are you sure you created the module in the Admin CP exactly how the image shows?
I just checked, it's exactly the same. I have no idea.
Reply With Quote
  #10  
Old 04-25-2017, 02:24 AM
KatFennec's Avatar
KatFennec KatFennec is offline
Member
 
Join Date: Apr 2017
Posts: 57
Gender: Female
Credits: 7,798
KatFennec is on a distinguished road
Default

Aquapyrofan and I are working together on this, so I've got a couple questions, since I'm having trouble getting this working as well. We've tried to set it exactly as you said, but it's still not working. As such, I was wondering whether the alchemy or item drop mods, or the fact that it was not installed at the domain's root, would be issues?

EDIT: tested on a clean install under WAMP, it still doesn't work

Last edited by KatFennec; 04-25-2017 at 03:51 AM.
Reply With Quote
Reply


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


All times are GMT -5. The time now is 11:21 AM.

Currently Active Users: 618 (0 members and 618 guests)
Threads: 4,080, Posts: 32,024, 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 - 2024, vBulletin Solutions Inc.
vBCommerce I v2.0.0 Gold ©2010, PixelFX Studios
vBCredits I v2.0.0 Gold ©2010, PixelFX Studios
Emoticons by darkmoon3636