1
fdj
replace XoopsFormButton by image
  • 2003/4/10 12:09

  • fdj

  • Just popping in

  • Posts: 51

  • Since: 2002/9/19


hello, i would like to change all the form buttons of my XOOPS web site. I saw that they were built like this (in include/storyform.inc.php) :

$button_tray->addElement(new XoopsFormButton('', 'post', _NW_POST, 'submit'));

what i would like to do is changing every "submit" by "image".
something like this =>
$button_tray->addElement(new XoopsFormButton('', 'post', _NW_POST, 'image', src='post.gif'));

can someone tell me how to change this.

thx for your help


2
Herko
Re: replace XoopsFormButton by image
  • 2003/4/10 14:12

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


I think you'll have to edit each template manually to get this...

Herko

3
fdj
Re: replace XoopsFormButton by image
  • 2003/4/10 16:18

  • fdj

  • Just popping in

  • Posts: 51

  • Since: 2002/9/19


hello Herko,
most of form buttons can't be edited from the theme manager. It seems that it's hardcoded so i would like to know how can i change for e.g the submit button of "submit news" => $button_tray->addElement(new XoopsFormButton('', 'post', _NW_POST, 'submit'));

4
Katmando
Re: replace XoopsFormButton by image
  • 2004/2/17 14:13

  • Katmando

  • Just popping in

  • Posts: 10

  • Since: 2003/1/4 1


I am not sure about this so some will have to confirm this. But if you want all the buttons to have the same image could you just hack the render function in the xoopsformbutton.php file?

function render(){
        return 
".$this->getType()."' class='formButton' name='".$this->getName()."'  id='".$this->getName()."' value='".$this->getValue()."'".$this->getExtra()." />";
    }


to something like

function render(){
        return 
".$this->getType()."' class='formButton' name='".$this->getName()."'  id='".$this->getName()."' value='".$this->getValue()."'".$this->getExtra()."  src='"'post.gif'"'/>";
    }

Login

Who's Online

236 user(s) are online (195 user(s) are browsing Support Forums)


Members: 0


Guests: 236


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Dec 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits