1611
Mamba
Re: (More ?) Useful Tags in User Message Manager
  • 2020/1/26 23:48

  • Mamba

  • Moderator

  • Posts: 11373

  • Since: 2004/4/23


Some of them work in the mail manager, because they are defined there, in /class/xoopsmailer.php

foreach ($this->toUsers as $user) {
            
// set some user specific variables
            
$subject str_replace('{X_UNAME}'$user->getVar('uname'), $this->subject);
            
$text    str_replace('{X_UID}'$user->getVar('uid'), $this->body);
            
$text    str_replace('{X_UEMAIL}'$user->getVar('email'), $text);
            
$text    str_replace('{X_UNAME}'$user->getVar('uname'), $text);
            
$text    str_replace('{X_UACTLINK}'XOOPS_URL '/register.php?op=actv&id=' $user->getVar('uid') . '&actkey=' $user->getVar('actkey'), $text);


You can also define them yourself in your module, as it was done, for example in SmartObject :

public static function sanitizeForCommonTags($text)
    {
        global 
$xoopsConfig;
        
$text str_replace('{X_SITENAME}'$xoopsConfig['sitename'], $text);
        
$text str_replace('{X_ADMINMAIL}'$xoopsConfig['adminmail'], $text);

        return 
$text;
    }


or in tdmspot:

$body             str_replace('{X_NAME}'$user_name$body);
            
$body             str_replace('{X_UNAME}'$user_uname$body);
            
$body             str_replace('{X_UEMAIL}'$user_email$body);
            
$body             str_replace('{X_ADMINMAIL}'$xoopsConfig['adminmail'], $body);
            
$body             str_replace('{X_SITENAME}'$xoopsConfig['sitename'], $body);
            
$body             str_replace('{X_SITEURL}'XOOPS_URL$body);
            
$tpitem['text']   = $body;
            
$meta_keywords    .= $body;
            
$meta_description .= $body;


Just search in all you modules for "{X_" and you'll find many examples of how it is done.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



1612
alain01
Re: (More ?) Useful Tags in User Message Manager
  • 2020/1/26 23:25

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Only
{X_ADMINMAIL}, {X_SITENAME}, {X_SITEURL} work on the user message manager.

Others, no.
May be cause contextual variables.



1613
alain01
Re: (More ?) Useful Tags in User Message Manager
  • 2020/1/26 22:42

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Thank you , i will try !
In which files can I find theses informations ?



1614
Mamba
Re: (More ?) Useful Tags in User Message Manager
  • 2020/1/26 22:27

  • Mamba

  • Moderator

  • Posts: 11373

  • Since: 2004/4/23


There are also few extra:
{X_ADMINMAIL}
{
X_SITENAME}
{
X_SITEURL}
{
X_ITEM_TYPE
{
X_ITEM_NAME}
{
X_ITEM_TITLE}
{
X_ITEM_URL}
{
X_MODULE}
{
X_COMMENT_URL}
{
X_UNSUBSCRIBE_URL}
{
X_NOTIFY_EVENT}
{
CATEGORY_TITLE}
{
EVENT_SUMMARY}
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



1615
alain01
(More ?) Useful Tags in User Message Manager
  • 2020/1/26 11:43

  • alain01

  • Just can't stay away

  • Posts: 530

  • Since: 2003/6/20


Hi,
For the User Message Manager (page /modules/system/admin.php?fct=mailusers),
i noticed this :
Quote:
{X_UID} will print user id
{X_UNAME} will print user name
{X_UEMAIL} will print user email
{X_UACTLINK} will print user activation link
Is there another tags (in 2.5.10 / 2.5.111) ?
I'm thinking in particular of smarty variables.
Quote:
'uname|name|email|user_avatar|url|user_icq|user_aim|user_yim|user_msnm|posts|user_from|user_occ|user_intrest|bio|user_sig'
For mail, if the name is not empty, the name is more relevant than the user name.
If we can use these variables, is it possible to write smarty tests in the message?
like :
<{if $member_info.name}>
    <{
$member_info.name}>
<{else}>
    <{
$member_info.uname}>
<{/if}>



1616
mjoel
help with mysql xoops query and msaccess database
  • 2020/1/26 5:47

  • mjoel

  • Quite a regular

  • Posts: 325

  • Since: 2006/12/9


Hi...i have this query where i have two tables mydepartments (xoops database) and department (msaccess database)

what i would like to do is to compare both of the tables and insert new data to xoops table from ms access table

how do i combine this two queries together ?
$sql"INSERT INTO ".$xoopsDB->prefix("mydepartments")."(`DEPTID`, `DEPTNAME`)
SELECT DEPTID,DEPTNAME FROM DEPARTMENTS AS o WHERE o.DEPTID NOT 
 IN (SELECT DEPTID FROM "
.$xoopsDB->prefix("mydepartments").")";


right now in xoops i reveive departments tables not exist error

i used odbc to connect to msaccess database
$conn=odbc_connect('mydata','','');
if (!
$conn)
  {exit(
"Connection Failed: " $conn);}

$sql="SELECT DEPTID,DEPTNAME FROM DEPARTMENTS";
$rs=odbc_exec($conn,$sql);
if (!
$rs)
  {exit(
"Error in SQL");}


thank you in advance for any input



1617
Lupin
Re: Cannot enter in PUBLISHER module administration ... but "sometimes" ...
  • 2020/1/24 19:44

  • Lupin

  • Just popping in

  • Posts: 92

  • Since: 2007/6/1 2


TYVM Mamba ,

I will report.

Pino



1618
Mamba
Re: Cannot enter in PUBLISHER module administration ... but "sometimes" ...
  • 2020/1/23 23:25

  • Mamba

  • Moderator

  • Posts: 11373

  • Since: 2004/4/23


Just comment out lines 92-95 in /admin/index.php:

//$newRelease = $utility::checkVerModule($helper);
//if (!empty($newRelease)) {
    //$adminObject->addItemButton($newRelease[0], $newRelease[1], 'download', 'style="color : Red"');
//}
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



1619
Mamba
Re: Getting a "403 Access denied" error when trying to access the Private Messages module
  • 2020/1/23 23:22

  • Mamba

  • Moderator

  • Posts: 11373

  • Since: 2004/4/23


Quote:
I just sent myself a PM. How is that even possible?

Why not? You can send yourself a text message on your phone, and you can send yourself an email!
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs



1620
Lupin
Re: Cannot enter in PUBLISHER module administration ... but "sometimes" ...
  • 2020/1/23 16:50

  • Lupin

  • Just popping in

  • Posts: 92

  • Since: 2007/6/1 2


Is anyone working on this problem?
Since yesterday none of the administrators has managed to enter the administration panel of the module !!!
Since we would soon need to go into production, is it possible to have a version without this "automatic data collector"?

Thanks

Pino




TopTop
« 1 ... 159 160 161 (162) 163 164 165 ... 29425 »



Login

Who's Online

612 user(s) are online (334 user(s) are browsing Support Forums)


Members: 0


Guests: 612


more...

Donat-O-Meter

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

Latest GitHub Commits