I'm trying to add links to custom blocks on my nuke site. Running 7.7. Using the admin interface to create custom blocks. Every link I've created, the destination is ignored and the link just redirects to the root of my site. When I return to the block editor, the link I defined is removed just leaving behind empty quotes.
Here's examples of my code (genericized).
Example 1:
Code:
Contact the <a href="mailto:webmaster@mysite.com">Webmaster</a>
<B> webmaster </b> who writes this book manages the following sites: <b ><br>
<a href="http://www.spaghettibrain.com">spaghettibrain.com</a>
<a href ="http://www.claudioerba.com">claudioerba.com</a>
Result - Code taken directly from the PHPNUKE HOWTO. Result is "spaghettibrain.com" links to http://www.mysite.com
Example 3:
Code:
<p>Visit the following sites</p><p><a href="http://www.website1.com/"><img src="http://www.mysite.com/images/content/image1.jpg"></a></p><p><a href="http://www.website2.com/"><img src="http://www.mysite.com/images/content/image2.jpg"></a></p><p><a href="http://www.website3.com"><img src="http://www.mysite.com/images/content/image3.jpg"></a></p>
Result - I had to add "img" to allowable HTML in my config.php to get images to appear and now they do. However, the images all link to http://www.mysite.com.
Anyone know how to resolve this?
Last edited by varan619 on Sun May 21, 2006 12:52 am; edited 1 time in total
When I start with that, my end result is visible $content and stuff around my images with incorrect links to my homepage. I tried to create a block-.php file from scratch and I just get an empty block. The instructions in the HOWTO, like the "remember" statement made above, I believe, assume an existing amount of knowledge that I do not possess.
What frustrates me most is that I have two websites running 7.7 and I can create a custom block on one using HTML and the link to an external destination works fine. I use the same exact code to my second site and it fails.
Therefore, I figure instead of trying radically new ways of making the block that there must be some config setting somewhere else that is causing my problem. Possibly in the theme somewhere as that is the essential difference between my two sites.
Good news is that when I hover over my images it displays the correct destinations and the alt text displays. However, when I click on the images, nothing happens. I tested the block I downloaded which includes a preset example and the same problem.
Sigh... Just having all kinds of problems. Despite the fact that I tried using the code tag, when I try to submit this post, I get the error "The html tags you attempted to use are not allowed." So I uploaded my code as an image instead.
Last edited by varan619 on Wed May 17, 2006 12:57 am; edited 1 time in total
That made it worse. Result was my images became empty cells with a cursor. The images display fine.
Also, I ultimately want the links to open in new windows but I don't know how to incorporate the target="_blank" into my code. I tried sticking where it would go in HTML world and that didn't work.
The other problem I'm having with my site which may or may not be related is that my topic icons are messed up. They are fine in the admin panel but my articles end up looking in the root directory of my site for the images.
Fantastic! That code worked. That block is 100% good to go. Thank you very much. I left a commented credit to you in the code.
I still have my underlying problem which I believe may be the source of all other evil. Going back to the first example in my OP (second example resolved).
1. I have a simple block called Disclaimer and at the end of my disclaimer text I want to put a link to contact the webmaster.
Code:
Contact the <a href="mailto:webmaster@mysite.com">Webmaster</a>
Result is that Webmaster links to http://www.mysite.com and when I return to the edit screen for the block the code has been altered to:
Code:
Contact the <a href="">Webmaster</a>
2. News is looking to the root directory (http://www.mysite.com) for my topic images. The path to my images works fine in the admin panel when I'm in the topics manager. But when I create an article and select the topic, the end result is a red x image.
Now I can bandage the red x of course by placing the images in the root directory of my site but there is part 2 to this problem.
If I simply copy that to my address bar and change myothersite to mysite, it gives me the intended result.
So my questions:
1. There seems to be some setting somewhere that is overiding specified locations and defaulting them to http://www.mysite.com (the root of my site). Where could this be?
2. Where can I redefine the link attached to my topic images in my news articles so that it uses modules.php instead of search.php.
And my understanding allowed me to find the solution to both of my problems.
varan619 wrote:
News is looking to the root directory (http://www.mysite.com) for my topic images. The path to my images works fine in the admin panel when I'm in the topics manager. But when I create an article and select the topic, the end result is a red x image.
1. There seems to be some setting somewhere that is overiding specified locations and defaulting them to http://www.mysite.com (the root of my site). Where could this be?
This is determined by the $tipath variable which is set in mainfile.php.
Code:
$tipath = "images/topics/"
This entry was missing from my mainfile.php due to the fact that is missing from the mainfile.php that is included with 77patched3dot2.
Likely, anyone who installs Nuke 7.7 with patch 3dot2 and the XPMidnight theme would run into these same problems so hopefully their google query will bring them here.
topic path should be set in config.php..if im not mistakin...and check the compatibility of ur theme be4 u upload it...i doub thats the end of ur problems with ur theme.
_________________
for those who STAND shall NEVER fall and those who fall shall rise once more...never give up the end is just another beginning.