Gossamer Forum
Skip to Content



Home : Products : Gossamer Links : Development, Plugins and Globals :

[ FREE PLUGIN ] ULTRAGlobals - Collection of Globals and routines

(Page 9 of 9)
> >
Quote Reply
Re: [Andy] Ideas please In reply to
Hi Andy,
with the following code I'm trying to print 3 random links of one category,
I don't want the whole include.html disyplayed, only the title and the image stored in the field "banner".
The url should be in title and in the image!

Code:
<%Plugins::ULTRAGlobals::Random_Links(3,'672')%>
<%if Random_Loop.length%>
<%loop Random_Loop%>
<%include link.html%>
<%endloop%>
<%endif%>

Can you tell me the the code?

Thanks
Matthias

Matthias
gpaed.de
Quote Reply
Re: [Matthias70] Ideas please In reply to
Why not just make a new template called link_basic.html, and change the "include" to use that template instead? Wink

Cheers

Andy (mod)
andy@ultranerds.com



Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Ideas please In reply to
It's only for a random image in the rightsidebar, and I don't want to have another link.thml for it :-)

Matthias
gpaed.de
Quote Reply
Re: [Matthias70] Ideas please In reply to
Ok, so why bother even doing an include then? Whistle

Just do something like:

Code:
<%Plugins::ULTRAGlobals::Random_Links(3,'672')%>
<%if Random_Loop.length%>
<%loop Random_Loop%>
<%Title%>
show whatever it is you want here

<%endloop%>
<%endif%>

Cheers

Andy (mod)
andy@ultranerds.com



Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Ideas please In reply to
Yes I know, but the "show whatever it is you want here is the problem :-)
I want to show an image from the database field "banner" with the link from the database.


Matthias
gpaed.de
Quote Reply
Re: [Matthias70] Ideas please In reply to
Hi,

Ok, please explain more. Where is the banner "stored"? You havn't really explained that - I thought it was just another field in your glinks_Links table ;)

Cheers

Andy (mod)
andy@ultranerds.com



Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Ideas please In reply to
O.K. found a solution by myself.
Tell me, if it there are some senseless parts :-)

Code:
<%Plugins::ULTRAGlobals::Random_Links(1,'672')%>
<%if Random_Loop.length%>
<%loop Random_Loop%>
<a href="<%URL%>" target="_blank"><%Title%></a><br />
<a href="<%URL%>" target="_blank">
<img border="0" src="<%Banner%>" <%if Width%>width="<%Width%>"<%endif%> <%if Height%>height="<%Height%>"<%endif%> title="<%Title%> >"</a>
<%endloop%>
<%endif%>

Matthias
gpaed.de
Quote Reply
Re: [Matthias70] Ideas please In reply to
Quote:
<%Title%>
show whatever it is you want here
&
Quote:
<a href="<%URL%>" target="_blank"><%Title%></a><br />
<a href="<%URL%>" target="_blank">
<img border="0" src="<%Banner%>" <%if Width%>width="<%Width%>"<%endif%> <%if Height%>height="<%Height%>"<%endif%> title="<%Title%> >"</a>

Both quotes above are the same thing and exactly what Andy suggested.

Where he writes 'show whatever is you want here' means, you can use link properties to design the output you desire.

Hope this helps.

Vishal

-------------------------------------------------------
Web Hosting Kit: A to Z of Web Hosting! http://www.webhostingkit.com/
Software Devil: Software Search Made Easy! http://www.softwaredevil.com/
-------------------------------------------------------
Quote Reply
Re: [Matthias70] Ideas please In reply to
Sure, thats fine (its what I suggested ;))

I'd change it a little bit though - as no point in having 2 <a href bits .. as it just adds more text than you need)

Try:

Code:
<%Plugins::ULTRAGlobals::Random_Links(1,'672')%>
<%if Random_Loop.length%>
<%loop Random_Loop%>
<a href="<%URL%>" target="_blank">
<%Title%><br />
<img border="0" src="<%Banner%>" <%if Width%>width="<%Width%>"<%endif%> <%if Height%>height="<%Height%>"<%endif%> title="<%Title%>" />
</a>
<%endloop%>
<%endif%>

Cheers

Andy (mod)
andy@ultranerds.com



Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] Ideas please In reply to
OK, Thanks for your help

Matthias
gpaed.de
> >