Welcome to Geeklog, Anonymous Saturday, January 04 2025 @ 11:12 pm EST
Geeklog Forums
Clarification on New Window on a link
Status: offline
ola_one
Forum User
Full Member
Registered: 06/28/03
Posts: 186
Really sorry to bother you all againl, but I went through the thread of a previous post, and I found that I needed to insert target=_blank in lib-common.php to enable new windows to open when one clicks on a link within Geeklog. Right now, when I click on a link, the new link takes over the browser, and I am out of Geeklog.
However, I am lost as to where exactly to insert the information.
I know that it is supposed to be within the following, but where exactly is the problem for me:
$newlinks [] = '<a href="' . $lcount . '" title="'
. $A['title'] . '">' . substr( $A['title'], 0, 16 )
. '...</a>' . LB;
}
else
{
$newlinks[] = '<a href="' . $lcount . '">'
. substr( $A['title'], 0, $itemlen ) . '</a>' . LB;
Should it be within the brackets after $newlinks, or should it be after a href or $lcount?
I am tempted to put it within the brackets but thought to ask first before messing up.
Thanks again
Ola
However, I am lost as to where exactly to insert the information.
I know that it is supposed to be within the following, but where exactly is the problem for me:
Text Formatted Code
{$newlinks [] = '<a href="' . $lcount . '" title="'
. $A['title'] . '">' . substr( $A['title'], 0, 16 )
. '...</a>' . LB;
}
else
{
$newlinks[] = '<a href="' . $lcount . '">'
. substr( $A['title'], 0, $itemlen ) . '</a>' . LB;
Should it be within the brackets after $newlinks, or should it be after a href or $lcount?
I am tempted to put it within the brackets but thought to ask first before messing up.
Thanks again
Ola
6
5
Quote
Status: offline
ola_one
Forum User
Full Member
Registered: 06/28/03
Posts: 186
Thanks Turias,
I have done as you said, but the window did not open in a separate page.
$newlinks [] = '<a target="_blank" href="' . $lcount . '" title="'
. $A['title'] . '">' . substr( $A['title'], 0, 16 )
. '...</a>' . LB;
}
else
{
$newlinks[] = '<a target="_blank" href="' . $lcount . '">'
. substr( $A['title'], 0, $itemlen ) . '</a>' . LB;
}
My linkdetails.thtml looks like the follwoing:
<strong><a href="{link_url}" target="_blank">{link_name}</a></strong> ({link_hits}) {link_edit}<br>
{link_description}
</li>
Is there something that I am missing?
Thansk
I have done as you said, but the window did not open in a separate page.
Text Formatted Code
{$newlinks [] = '<a target="_blank" href="' . $lcount . '" title="'
. $A['title'] . '">' . substr( $A['title'], 0, 16 )
. '...</a>' . LB;
}
else
{
$newlinks[] = '<a target="_blank" href="' . $lcount . '">'
. substr( $A['title'], 0, $itemlen ) . '</a>' . LB;
}
My linkdetails.thtml looks like the follwoing:
Text Formatted Code
<li><strong><a href="{link_url}" target="_blank">{link_name}</a></strong> ({link_hits}) {link_edit}<br>
{link_description}
</li>
Is there something that I am missing?
Thansk
6
6
Quote
Status: offline
ola_one
Forum User
Full Member
Registered: 06/28/03
Posts: 186
Sorry about that, I am trying to click the following:
http://www.adeseyeogunlewe.com
You will see a drop down box at the right in a weather block. The weather is coming directly from Yahoo Weather. If you pick any of the towns, it takes you to yahoo weather forecast for that town, but the page overwrites the above homw page.
Thanks
http://www.adeseyeogunlewe.com
You will see a drop down box at the right in a weather block. The weather is coming directly from Yahoo Weather. If you pick any of the towns, it takes you to yahoo weather forecast for that town, but the page overwrites the above homw page.
Thanks
4
8
Quote
Status: offline
Turias
Forum User
Full Member
Registered: 10/20/03
Posts: 807
Text Formatted Code
function goToURL(form) {var myindex=form.select1.selectedIndex
if(!myindex=="")
{
window.location.href=form.select1.options[myindex].value;
}
}
function goToURL2(form) {
var myindex=form.select2.selectedIndex
if(!myindex=="")
{
window.open(form.select2.options[myindex].value);
}
}
becomes
Text Formatted Code
function goToURL(form) {
var myindex=form.select1.selectedIndex
if(!myindex=="")
{
window.open(form.select1.options[myindex].value);
}
}
function goToURL2(form) {
var myindex=form.select2.selectedIndex
if(!myindex=="")
{
window.open(form.select2.options[myindex].value);
}
}
6
8
Quote
All times are EST. The time is now 11:12 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content