1
Xavi_R
Standardising URL formats - Help required
  • 2009/4/26 10:43

  • Xavi_R

  • Just popping in

  • Posts: 8

  • Since: 2008/3/20


Unfortunately my Domain Name Provider's web forwarding service is restrictive to say the least and I have found that the only way to get around this is to use a dynamic DNS service to help with my website redirection to allow me to host subdomains.

I then found I also have a problem with the XOOPS 2.3.3 CMS. The domain names I have used are fictitious as I still want the sites to remain priate until I have got them up and running. The setup is as follows:
Main Domain Name: http://paul.tandt.co.uk
Dynamc DNS Name: http://my.dns.pointer.org

Due to the restrictions on my Main Domain redirection. something like "http://paul.tandt.co.uk/themes/default/icons/favicon.ico" does not work however "http://my.dns.pointer.org/include/xoops.js" does work.

The result is that the opening page of the website and the home page once signed in have got little/no formatting although the Admin pages work fine. I have taken an extract from the sources of the opening page and the Admin page.

Extract from Opening Page

<!-- Rss -->
<link rel="alternate" type="application/rss+xml" title="" href="http://paul.tandt.co.uk/backend.php" />

<!-- Favicon -->
<link rel="shortcut icon" type="image/ico" href="http://paul.tandt.co.uk/themes/default/icons/favicon.ico" />
<link rel="icon" type="image/png" href="http://paul.tandt.co.uk/themes/default/icons/favicon.png" />
<!-- Sheet Css -->
<link rel="stylesheet" type="text/css" media="all" title="Style sheet" href="http://paul.tandt.co.uk/xoops.css" />
<link rel="stylesheet" type="text/css" media="all" title="Style sheet" href="http://paul.tandt.co.uk/themes/default/style.css" />

<!-- customized header contents -->
<meta http-equiv="Content-Script-Type" content="text/javascript" />

<meta http-equiv="Content-Style-Type" content="text/css" />
<script type="text/javascript" src="http://my.dns.pointer.org/include/xoops.js">
</script>
<link rel="stylesheet" href="http://my.dns.pointer.org/language/english/style.css" type="text/css" />


Extract from Administration Menu

<link rel="stylesheet" type="text/css" media="all" href="http://my.dns.pointer.org/xoops.css" /><link rel="stylesheet" type="text/css" media="all" href="http://my.dns.pointer.org/modules/system/class/gui/default/css/style.css" /><link rel="stylesheet" type="text/css" media="all" href="http://my.dns.pointer.org/modules/system/class/gui/default/css/en.css" /><link rel="stylesheet" type="text/css" media="all" href="http://my.dns.pointer.org/language/english/style.css" />
</head>
<body>
<table border='0' width='100%' cellspacing='0' cellpadding='0'>
<tr>
<td bgcolor='#2a75c5' background='http://my.dns.pointer.org/modules/system/class/gui/default/images/xo-banner_bg.png'><a href='http://xoops.sourceforge.net/' rel='external'><img src='http://my.dns.pointer.org/modules/system/class/gui/default/images/xoops-logo.png' alt='Paul's Private Page' /></a></td>

<td align='right' bgcolor='#9F009F' background='http://my.dns.pointer.org/modules/system/class/gui/default/images/xo-banner_bg.png' colspan='2'><img src='http://my.dns.pointer.org/modules/system/class/gui/default/images/xoops23.gif' alt='' /></td>
</tr>
<tr>
<td align='left' colspan='3' class='bg5'>
<table border='0' width='100%' cellspacing='0' cellpadding='0'>
<tr>
<td width='1%'><img src='http://my.dns.pointer.org/modules/system/class/gui/default/images/hbar_left.gif' width='16' height='23' /></td>
<td class='hbar_middle'>
&nbsp;« <a href='http://my.dns.pointer.org/'>Home Page</a>

&nbsp;|&nbsp;<a href='http://my.dns.pointer.org/admin.php'>Control Panel Home</a>
&nbsp;|&nbsp;<strong>XOOPS »</strong>


I have looked at the theme page and taken an extract of this:
<!-- Rss -->
<link rel="alternate" type="application/rss+xml" title="" href="<{xoAppUrl backend.php}>" />

<!-- Favicon -->
<link rel="shortcut icon" type="image/ico" href="<{xoImgUrl icons/favicon.ico}>" />
<link rel="icon" type="image/png" href="<{xoImgUrl icons/favicon.png}>" />

What I would like to know is how can I change things like xoAppUrl, xoImgUrl and any other similar variables to use the value of XOOPS_URL set in the mainfile.config

Any help would be appreciated

Xavi

2
Xavi_R
Re: Standardising URL formats - Help required
  • 2009/4/26 10:46

  • Xavi_R

  • Just popping in

  • Posts: 8

  • Since: 2008/3/20


Oh! Before anyone tells me to change my DNS provider, I am trying to avoid that as much as I can for personal reasons.

3
trabis
Re: Standardising URL formats - Help required
  • 2009/4/26 11:01

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


File you're looking is class/smarty/xoops_plugins/compiler.xoAppUrl.php which has a dynamic way to find the url

But, you can replace <{xoAppUrl backend.php}> with <{$xoops_url}>/backend.php

With $xoops_url you are sure to use the url defined in mainfile.


4
Xavi_R
Re: Standardising URL formats - Help required
  • 2009/4/28 16:38

  • Xavi_R

  • Just popping in

  • Posts: 8

  • Since: 2008/3/20


Thanks very much for your input it has made my life alot easier. Saying that, I have had to start learning about PHP debugging - a completely new learning curve for me.

Xavi

Login

Who's Online

208 user(s) are online (132 user(s) are browsing Support Forums)


Members: 0


Guests: 208


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