1
Xtracted
xoopsuser hack, Extra Info (Bio)
  • 2006/11/10 13:14

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


I am hacking xoopsuser a bit to give the "extra info" field a bit more function. I have fixed so you use a editor instead of the regular textfield to edit it and I want to make it possible to insert pretty much information into it.

I tried to just change the database field for it but somewhere the input is capped at 255 characters.. If i input more it ends at 255 and three dots are added after the text...

I assume that somewhere there is a limitation to how much text you allowed to have in the extra info field. Can someone point me in the right direction?

2
iHackCode
Re: xoopsuser hack, Extra Info (Bio)

file: 'XooPS'/edituser.php
$edituser->setVar('bio'xoops_substr($_POST['bio'], 0255));


I Believe That Is It.
CBB / LatestNews / Publisher / XM-Spotlight

(ノ◕ヮ◕)ノ*:・゚✧

3
Xtracted
Re: xoopsuser hack, Extra Info (Bio)
  • 2006/11/11 12:50

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


Yes! There it was, totally missed that line somehow.. *blush*


Now I have a followup problem.. When I allow more content in the bio field, I also need to make the editor larger to make it easier to modify..

This is my code for the editor:

$bio_tray = new XoopsFormElementTray(_US_EXTRAINFO'<br />');
    include_once 
'include/xoopscodes.php';
    
$bio_tarea = new XoopsFormDhtmlTextArea(_US_EXTRAINFO'bio'$xoopsUser->getVar('bio''E'));
    
$bio_tray->addElement($bio_tarea);


Is it possible to change the size of just that editor somehow without changing all the editors in the entire page?

4
iHackCode
Re: xoopsuser hack, Extra Info (Bio)

..Link

...
68      /**
  69       * Constructor
  70       *
  71       * @param    string  $caption    Caption
  72       * @param    string  $name       "name" attribute
  73       * @param    string  $value      Initial text
  74       * @param    int     $rows       Number of rows
  75       * @param    int     $cols       Number of columns
  76       * @param    string  $hiddentext Hidden Text
  77       */
  
78      function XoopsFormDhtmlTextArea($caption$name$value$rows=5$cols=50$hiddentext="xoopsHiddenText")
  
79      {
  
80          $this->XoopsFormTextArea($caption$name$value$rows$cols);
  
81          $this->_hiddenText $hiddentext;
  
82      }
  
83


Here. Just Add a Custom Size For The rows, cols.

and example:
$bio_tarea = new XoopsFormDhtmlTextArea(_US_EXTRAINFO'bio'$xoopsUser->getVar('bio''E')[b][color=009900] ,10,50[/color][/b]);
CBB / LatestNews / Publisher / XM-Spotlight

(ノ◕ヮ◕)ノ*:・゚✧

5
Xtracted
Re: xoopsuser hack, Extra Info (Bio)
  • 2006/11/13 13:54

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


Sweet, there it was..


This works well so far, Ill just keep spamming the questions =)

How do I make it use another editor, koivi for example, since I noticed the regular editor to be a bit too limited?

6
iHackCode
Re: xoopsuser hack, Extra Info (Bio)

im not sure. i havent played with the other editors yet.
CBB / LatestNews / Publisher / XM-Spotlight

(ノ◕ヮ◕)ノ*:・゚✧

Login

Who's Online

115 user(s) are online (95 user(s) are browsing Support Forums)


Members: 0


Guests: 115


more...

Donat-O-Meter

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

Latest GitHub Commits