Hack Forums
MyBB Help Desk - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Webmasters (https://hackforums.net/forumdisplay.php?fid=141)
+---- Forum: Website Construction (https://hackforums.net/forumdisplay.php?fid=50)
+---- Thread: MyBB Help Desk (/showthread.php?tid=4505516)

Pages: Pages 1 2


MyBB Help Desk - Nasyr - Oct 24, 2014


(Nov 3, 2014 04:37 PM)Red™ Wrote:  Thanks for the help, fixed the problem with my awards system.

(Nov 3, 2014 03:18 PM)Music Producer Wrote:  Vouch for nasyr, brilliant support and help :)

(Dec 27, 2014 08:33 PM)Autononymous Wrote:  I'd like to vouch for Nasyr, is a true MyBB guru.



* - JumpWar - Oct 25, 2014

Hi, maybe you can help me with a problem I neglected for some time now but need fixed for a theme I am building.

I want to display the last posters avatar.
My approach here is to create a variable holding the link to the avatar. As those links are saved in the users table I added the following code to "forumdisplay.php" on line 1257 shortly after $lastposter and $lastposteruid are defined.
Code
$query = $db->simple_select('users', 'avatar', "uid = $lastposteruid");
$result = $db->fetch_array($query);
$lastposter_avatar = $result['avatar'];
My assumption is that I can now use
Code
<img src="{$lastposter_avatar}" class="poster-img">
in my template to display the last posters avatar.

This however does not work as I expect it to. How would I go about this?
And whats the best practice for adding variables? (Maybe you can turn that into a tut one day)

Would appreciate you help on this :)


* - .russo - Oct 25, 2014

(Oct 25, 2014 01:18 PM)JumpWar Wrote:  
Code
$query = $db->simple_select('users', 'avatar', "uid = $lastposteruid");
$result = $db->fetch_array($query);
$lastposter_avatar = $result['avatar'];

Quote:$query = $db->simple_select('users', 'avatar', "uid = $lastposteruid");

change to

Quote:$query = $db->simple_select('users', 'avatar', "`uid` = '$lastposteruid'");

They make a difference.


* - JumpWar - Oct 26, 2014

(Oct 25, 2014 03:29 PM)☯ Wrote:  They make a difference.

Hi, thanks for the reply 🤝

Implemented your suggestion but didn't change anything as far as I can see. Also have no idea how to debug this properly.

Could you link me a source about using ` in queries? would like to learn more about that not sure which subject this would fall under.


* - Nasyr - Oct 26, 2014

(Oct 26, 2014 08:08 AM)JumpWar Wrote:  Hi, thanks for the reply 🤝

Implemented your suggestion but didn't change anything as far as I can see. Also have no idea how to debug this properly.

Could you link me a source about using ` in queries? would like to learn more about that not sure which subject this would fall under.

Can you link me to your forum so I can see it for myself?


* - JumpWar - Oct 26, 2014

(Oct 26, 2014 09:01 AM)Nasyr Wrote:  Can you link me to your forum so I can see it for myself?

Currently only have it on a local server. What would you want to look at?
The displayed forum just has an img tag with an empty src, would you want to see the templates?


* - Nasyr - Nov 2, 2014

Still offering support and now offering services: https://hackforums.net/showthread.php?tid=4505612


* - Rebel Energy - Nov 2, 2014

Are you able too offer any advice here please mate (ref-inferno shout):~

https://hackforums.net/showthread.php?tid=4517313&pid=43127214


* - Nasyr - Nov 2, 2014

(Nov 2, 2014 01:01 PM)Rebel Energy Wrote:  Are you able too offer any advice here please mate (ref-inferno shout):~

https://hackforums.net/showthread.php?tid=4517313&pid=43127214

Please send me a PM with your Skype so I can assist further.


* - Tabs - Nov 2, 2014

how do i get these

https://gyazo.com/a02b3dd00ba1736fdac24dffacbc3d0b


* - Nasyr - Nov 2, 2014

(Nov 2, 2014 05:33 PM)Sizzurup Wrote:  how do i get these

https://gyazo.com/a02b3dd00ba1736fdac24dffacbc3d0b

Those are Tabs, made my Omni (Omniscient).
Paid Version: http://www.mybbcentral.com/thread-7687.html
Free Version: http://mods.mybb.com/view/mytabs

Paid version is the one HackForums use.


* - Red™ - Nov 2, 2014

https://hackforums.net/showthread.php?tid=4514950

I have tried to fix this problem with the help from the other posts but I still continue to get the errors.


* - Nasyr - Nov 3, 2014

(Nov 2, 2014 09:59 PM)Red™ Wrote:  https://hackforums.net/showthread.php?tid=4514950

I have tried to fix this problem with the help from the other posts but I still continue to get the errors.

Have you followed the on screen instructions as shown?


* - Red™ - Nov 3, 2014

(Nov 3, 2014 04:36 AM)Nasyr Wrote:  Have you followed the on screen instructions as shown?

What on screen instructions are you talking about?


* - Sucker for pain - Nov 3, 2014

Vouch for nasyr, brilliant support and help :)