1
equinox
Is a Function needed to use <{$xoops_url}> as http://... ?
  • 2010/2/7 1:34

  • equinox

  • Just popping in

  • Posts: 13

  • Since: 2010/1/17


Hi at all,

i tried to use
<a href="<{$xoops_url}>/index.php">Back to Home</a>
in a *.php page in my Uploadfolder.
I know for using any contents that is not provided in xoops, there must be the mainfile.php included to display all correctly.
I also tried the mainfile.php, the header.php and the footer.php to include too, but all does not work.

Is there a Hack needed to use the xoops-Variables in extra pages?

In Themes i can provide some new variables they i would like to use with:
"<{assign var="name" value=$name->folderName|cat:'/name'}>"
Is a part like this needed too to solve my problem?

THX for all Answers and Greetings from Germany
Thom

2
ghia
Re: Is a Function needed to use <{$xoops_url}> as http://... ?
  • 2010/2/7 9:44

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


Quote:
<a href="<{$xoops_url}>/index.php">Back to Home</a>
This is Smarty syntax for using in templates (.html).
For PHP use eg:
'<a href="'.XOOPS_URL.'/index.php">Back to Home</a>'

3
equinox
Re: Is a Function needed to use <{$xoops_url}> as http://... ?
  • 2010/2/7 13:21

  • equinox

  • Just popping in

  • Posts: 13

  • Since: 2010/1/17


Hi ghia,

thx for it, but that is not what i mean.
I would like to display "http://www.mydomain.com/" at using <{$xoops_url}>, but <{$xoops_url}> is displayed by hover the link on my page, thats result by click the link an http-error (page can not be found...). Sure, because the var is not displayed as "http://..."

I am Sorry for misunderstanding, the Homelink (as example) is in a html part above php-code.

4
ghia
Re: Is a Function needed to use <{$xoops_url}> as http://... ?
  • 2010/2/7 15:34

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


Quote:
in a html part above php-code
That is not enough. It needs to be in a template file.
Try with:
<?php echo XOOPS_URL?>

5
equinox
Re: Is a Function needed to use <{$xoops_url}> as http://... ?
  • 2010/2/8 14:38

  • equinox

  • Just popping in

  • Posts: 13

  • Since: 2010/1/17


Hi ghia,
thx as first, if i use now this PHP-code has result "http://..." is displaying. Great job, thx.

My code looks now like a code from Wordpress *LOL*

BTW: Is nothing else possible to use <{$xoops_url}>?
It must be PHP-code for pages that not inside a module?
(Thats only a question. I want to understand how inside a module some variables like <{$xoops_url}> can be used, and just only there.)

Greetings
Thomas

Login

Who's Online

126 user(s) are online (90 user(s) are browsing Support Forums)


Members: 0


Guests: 126


more...

Donat-O-Meter

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

Latest GitHub Commits