Forum Description Plugin

  1. 4 years ago

    [deleted]

    3 Feb 2015

    Hello, i'm super new in esoTalk community can anyone help me with the issue below? Thanks in advance for your help.

    i'm a webdesigner but not really good with PHP programing.

    So, i'm creating a simple description plugin which will appear next to logo;

    Code will put somewhere in default.master.php:

    <?php $data["$forumDes"]; ?>

    What we supposed to use instead addToHead ??

    public function handler_init($sender , $data)
    	{
    		if ($forumDes = C("EsoDes.forumDes")) {
    			$sender->addToHead("$forumDes");							
    				}
    	}

    I'll share full plugin once will completaly work. Only need to solve this :-) Thank you.

  2. This is nice. It would be great if the description (tagline) is also added to <title> tag on homepage

  3. [deleted]

    4 Feb 2015

    Currently it shows only in <head> tag -image-

    I would really appreciate If anyone can help.

  4. Edited 4 years ago by Felli

    @operadevil Currently it shows only in <head> tag -image-

    I would really appreciate If anyone can help.

    You could just add plain text after line 44 in default.master.php
    -image-

  5. [deleted]

    5 Feb 2015

    c'mon @Felli are you serious ? :-) the goal is here to create a simple plugin which will be editable through admin so users won't have to modify the php file. Anyway :) thanks for your help Felli :)

  6. Thirtysixway

    10 Feb 2015 Moderator Answer

    There are a few ways you could look at doing this, possibly using bits from a few of them

    1. You can override a view for the overall page and include a variable that has the description. I'd look at the docs regarding this . You could override default.master.php ? Or something similar. Not sure if you can actually override this or not but you can look into that.

    2. The title is displayed via <h1 id='forumTitle'><a href='<?php echo URL(""); ?>'><?php echo $data["forumTitle"]; ?></a></h1> in default.master.php. If you can get your data into that forumTitle variable you could display it there - though it'd be linked and styled..

    3. If you're familiar with javascript you could also inject a resource via your plugin and use javascript/css to insert the description where you want it in the page. This probably wouldn't be the most ideal but it could work.

  7. [deleted]

    15 Feb 2015
  8. Yes I would defiantly like to see a plugin for this, where we can have the logo and description together?
    Exactly like Esotalk without us having to edit core files and saving us all from messing up php files.

  9. @Tech Yes I would defiantly like to see a plugin for this, where we can have the logo and description together?
    Exactly like Esotalk without us having to edit core files and saving us all from messing up php files.

    The plugin has been created but it's only a description plugin, nothing like how Toby has done this forum. lol

  10. Well I hope toby doesn't mind in explaining in how he did it cause the logo and description looks great :)

  11. @Tech Well I hope toby doesn't mind in explaining in how he did it cause the logo and description looks great :)

    He edited the >core>views>default.master.php line 45.

  12. Thanks that's now solved ;)

 

or Sign Up to reply!