Welcome, Guest. Please Login or Register.
November 28, 2024, 02:35:28 AM
Home Help Search Log in Register
News: SMF is the next generation in forum software, almost completely re-written from the ground up, make sure you don't fall for cheap imitations that suffer from feature bloat!

YaBB SE Community  |  Development  |  Completed mods  |  [Done 1.5.1] recentPoll & New recentTopics() for SSI.php « previous next »
Pages: 1 2 3 [4] 5 Reply Ignore Print
Author Topic: [Done 1.5.1] recentPoll & New recentTopics() for SSI.php  (Read 40060 times)
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #45 on: April 15, 2003, 12:12:23 AM »
Reply with quote

u can just put html code there, like:
<img src="http://www.yoursite.com/images/image1.jpg" border="0" />
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
maime
Noobie
*
Posts: 34


Let there be no doubt about it...I am a flying pig

WWW
Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #46 on: April 15, 2003, 12:30:14 AM »
Reply with quote

thanks spaceman :) did not know it was that easy.

I actualy managed it in an other way..  i couldnot stand it that i never found out something myself and i have to say its my first real found out myself php coding ;D
finally  ;)i did

echo "<tr><td>$img[ltopic][$recent_topic]</td></tr>\n";

and put a reference in the english.Lng file

$img['ltopic'] = '<img src="' . $imagesdir . '/ltopic.gif" alt="' . $txt[333] . '" title="' . $txt[333] . '" border="0" />';

yep,yep  :) my first php coding i am quiet pleased with myself and gonna eat a lot of chocolat now

your  <img src="http://www.yoursite.com/images/image1.jpg" border="0" /> is much more efficient though ;) i know
Logged
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #47 on: April 15, 2003, 12:45:43 AM »
Reply with quote

Quote from: maime on April 15, 2003, 12:30:14 AM
echo "<tr><td>$img[ltopic][$recent_topic]...
actually that's not the proper way, u can just do it like:
echo "<tr><td>$img[ltopic]...
because ltopic is an array index in $img variable
if you do like $img[][] it will be a 2d array, array inside an array (might be a bit confusing concept for a beginner :P)

Quotemy first php coding i am quiet pleased with myself and gonna eat a lot of chocolat now
hmm... chocolate  :P
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
QuanTum
Noobie
*
Posts: 7


I'm a llama!

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #48 on: April 15, 2003, 11:25:18 AM »
Reply with quote

Hi,

ive just installed your mod and it works great, no problems at all. i was just wondering if i could request a feature?

my page currently shows the last 5 topics on the main page, would it be possible to make some sort of archive that shows all the topics? or say 50 topics? the problem is, that the amount of topics displayed is defined in ssi.php . Is there some way around this?

any help would be great
Logged
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #49 on: April 15, 2003, 10:23:23 PM »
Reply with quote

open the new SSI.php, search forfunction recentTopics ($template = "rTopics_template.php")
{
   global $settings, $scripturl, $txt, $censored, $db_prefix, $num_recentTopics, $username;
replace withfunction recentTopics ($template = "rTopics_template.php", $num_recentTopics = 5)
{
   global $settings, $scripturl, $txt, $censored, $db_prefix, $username;


then when calling the function, use:
recentTopics("templatename.php", numOfTopics)
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
QuanTum
Noobie
*
Posts: 7


I'm a llama!

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #50 on: April 16, 2003, 02:15:46 AM »
Reply with quote

ahh great ! :)

thanks alot
Logged
QuanTum
Noobie
*
Posts: 7


I'm a llama!

Re:[Done 1.5.x] recentPoll & New recentTopics() for SSI.php
« Reply #51 on: April 16, 2003, 02:25:27 AM »
Reply with quote

ooo when i use that code i get an error on the page

Database Error

Please try again. If you come back to this error screen, report the error to an administrator.



any ideas?
thanks
Logged
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #52 on: April 19, 2003, 11:18:09 AM »
Reply with quote

v1.4 is released following the security/bug release of 1.5.1 -> http://www.yabbse.org/community/index.php?board=9;action=display;threadid=21654
it's strongly recommended to upgrade your mod
if u're using BoardMod, it should be only around 4 clicks
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
Zulu
Full Member
***
Posts: 104


I'm no longer a llama, I'm a Monkey

WWW
Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #53 on: April 22, 2003, 01:52:17 AM »
Reply with quote

Would it be possible to have it to take the latest poll from a certain board. So you can for example have a (might even be hidden) poll board, and just view te poll on your website ?
Logged

Webby @ RFI
Formerly known as PtPazuzu
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #54 on: April 22, 2003, 02:07:13 AM »
Reply with quote

u're right, i havent set the permission thing
for now if u want to show polls only from a certain board: search for            LEFT JOIN `{$db_prefix}topics` AS t ON (t.ID_POLL=p.ID_POLL)add after         WHERE t.ID_BOARD = '12'and change that 12 with the board number
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #55 on: April 22, 2003, 02:35:41 AM »
Reply with quote

released v1.5
Changelogs:
• New in v1.5:
 - recentpoll now not showing hidden boards unless the user has the permission
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
Daniel D.
Mod Team
YaBB God
*****
Posts: 2935


Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #56 on: April 26, 2003, 11:20:10 AM »
Reply with quote

German:

$polltxt[1] = "Umfrage nicht gefunden!";
$polltxt[2] = "Umfrage ist deaktiviert!";
$polltxt[3] = 'Um abzustimmen, musst Du eingeloggt sein. Wenn Du noch keinen Account hast, <a href="' . $scripturl . ';action=register">registriere</a> Dich bitte.';
$polltxt[4] = "Kommentare anschauen";
$polltxt[5] = "Ergebnis anschauen";
Logged

Metho
Sr. Member
****
Posts: 342


I'm a llama!

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #57 on: May 07, 2003, 04:54:27 AM »
Reply with quote

Hiya Spiff,
Just wanted to say great mod, and is exactly what I was looking for (the poll portion). I do have one small question. When my poll displays, seperating View results and view comments is a | character, and this in turn creates a white space between the two options. I went into english.lng and found this line:
$polltxt[4] = "View comments";
$polltxt[5] = "View results";

if ($MenuType == 1)
{
   $menusep = ' | ';

Which I assumed was that seperator command. However, I tried leaving white space, or just replacing it with another symbol, yet it didn't change on the page. Am I looking at the wrong thing, is there a way around this, or is it stuck like that?

Thanks in advance,

Meth
Logged

Spaceman-Spiff
Mod Team
YaBB God
*****
Posts: 3689


My $txt[228]

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #58 on: May 07, 2003, 07:39:14 AM »
Reply with quote

edit SSI.php:
<a href="' . $url . 'action=viewResult">' . $polltxt[5] . '</a> | ' . $viewComments . 'and<td class="' . $bodystyle . '">' . $txt['yse24'] . ': ' . $totalvotes . ' | ' . $viewComments . '</td>
Logged

   My mods, ysePak, codes, tutorials
    Support question IMs = bad.
Metho
Sr. Member
****
Posts: 342


I'm a llama!

Re:[Done 1.5.1] recentPoll & New recentTopics() for SSI.php
« Reply #59 on: May 07, 2003, 03:00:09 PM »
Reply with quote

:D
That did it.

Thanks much,

Methonis
Logged

Pages: 1 2 3 [4] 5 Reply Ignore Print 
YaBB SE Community  |  Development  |  Completed mods  |  [Done 1.5.1] recentPoll & New recentTopics() for SSI.php « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.029 seconds with 20 queries.