joomla query

Posted on 2009-02-17
Last Modified: 2012-06-27
i am new to this site..
and really i have learnt a lot from it...

i am working with a joomla programmer..
but we are stuck in between...
we are getting confused as to how to add advertisements at the top of the joomla site above header...

i hope some 1 can give me appropriate coding for that
Question by:pranav1andonly
    LVL 5

    Expert Comment

    by:Luis Carlos Clara Fernandes
    Only plugins could add entries to the header.  Look one of this plugins  and see how to do it.
    I hope it helps.
    Luis C. Fernandes

    Author Comment

    thnx clarafer i'l check it...
    and then accept it as a solution :p

    Author Comment

    but this is a paid plugin..
    can any 1 get me a free plugin...
    LVL 5

    Expert Comment

    by:Luis Carlos Clara Fernandes
    I downloaded for you. But this is a plugin that could shows you how to add entries in your joomla header.
    LVL 5

    Expert Comment

    by:Luis Carlos Clara Fernandes
    I could upload php files, but there is the code your concerned

    //Joomla restrict
    defined( '_JEXEC' ) or die( 'Restricted access' );
    //Get mainframe
    $mainframe->registerEvent( 'onPrepareContent', 'pluginBWgoogleverifiedplugin' );
    //Insert meta tag in header

    Open in new window


    Author Comment

    hii clarafer..
    thnx for helping..
    but by using this code i am unable to add advertisement at the top of the site

    Accepted Solution

    None of the previous comments apply. It sounds as though you wish to create a module position within the template. Once youve designated where this new position loads,  you can either publish to this position using an "ad" module, or simply use a custom html module containing your HTML.

    In order to best clearly answer your question, I would need to know your Joomla version (J1.x and J1.5 version have different methods for loading modules) - your default template would also be helpful so we dont create a module which already exists.

    There also exists different methods for hiding these modules when not in use, but if you intend on having this module (ad) display on all pages, that shouldnt be a concern.

    Finally, there are parameters that allow you to set how you would like your modules to display, but keeping it simply, ill show you the minimalist methods

    So in a nutshell:

    1. Modify your active (default) template to include a new module position
    2. Publish a module to this new position through the Joomla admin panel

    Hope this helps point you in the right direction!
    // Below is the standard method for creating modules within J1.5
    <jdoc:include type="modules" name="your_new_module_position_name" style="xhtml" />
    // Below is the standard method for creating modules within J1.x
    <?php mosLoadModules ( 'your_new_module_position_name', -1); ?>

    Open in new window


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Is Threat Intelligence?

    Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

    Shoutout to Emily Plummer ( for giving me this article! She did most of it, I just finished it up and posted it for her :)    Introduction In a previous article (http://www.experts-exchang…
    Online collaboration is quickly becoming embedded in the workplace, and its benefits are tangible. See what the current landscape looks like and what the future holds for collaboration tools and the future of work.
    The viewer will learn how to count occurrences of each item in an array.
    In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now