WordPress.org

Ready to get started?Download WordPress

Forums

Hero
How to add or change the slider? (7 posts)

  1. wpuser7
    Member
    Posted 1 year ago #

    I've been try to change the slider. because it only offers 2 slides.
    Is there a way to change properly? I've tried different sliders like nivo, easing and oqey sliders. I understand that you have to replace the php code in the php template, but it's not working. It doesn't get the specified categories that contains posts that has images in it. Please Help! Thank you!

    http://wordpress.org/extend/themes/hero/

  2. wpuser7
    Member
    Posted 1 year ago #

    It only works when i use the default php code and changes the 2 images sliders in its theme options namely "core"

  3. agentna
    Member
    Posted 1 year ago #

    Where it is that you add "core", is it in the homepage settings? Thanks

  4. adeelafzal
    Member
    Posted 1 year ago #

    to add slider goto front-page.php
    replace <=2 to no of slides u want
    i need 4
    <?php for ($i = 1; $i <= 4; $i++)
    goto cpanel in
    wp-content/themes/hero/images
    add slide3.png
    and so on which u want.
    i m stuck with black box... if any one have any solution regarding black box change with slider coz default it allows 2 black box but for 3 and 4 i dont have any idea.
    u need to disable black box from theme options :-)
    thank and regards

    [ redacted, support is offered via the forum and not email ]

  5. KareemAtif
    Member
    Posted 1 year ago #

    @adeelafzal: Thanks a lot :)

    After increasing slider number and you would like an easy way to add more slides from Theme Options like you did before:
    find Options.php in theme folder and scroll to line 91
    and copy this

    $options[] = array( "name" => "Slider heading 4",
    						"desc" => "Heading for the slider.",
    						"id" => "slider_head4",
    						"std" => "",
    						"type" => "text");
    
    	$options[] = array( "name" => "Slider text 4",
    						"desc" => "Textarea description of slider.",
    						"id" => "slider_text4",
    						"std" => "",
    						"type" => "textarea");
    
    	$options[] = array( "name" => "Slider image 4",
    						"desc" => "963px x 350px exact. Upload your image for homepage slider.",
    						"id" => "slider_image4",
    						"type" => "upload");
    
    	$options[] = array( "name" => "Slider read more link",
    						"desc" => "Paste here the link of the page or post.",
    						"id" => "slider_link4",
    						"std" => "",
    						"type" => "text");

    and paste it after line 135 and change number 4 to whatever the slide count you are on.
    repeat this code as much as you have already changed slider numbers according to previous post.

  6. adeelafzal
    Member
    Posted 1 year ago #

    @KareemAtif JAZAKALLAH KHAIR dear

    u have solved my problem .. but i would like to share one thing if any person wish to change the slider box opacity then he will goto cpanel and find nivo-slider.css and add opacity:0.85; in caption id..

    thanks and regards.

  7. agentna
    Member
    Posted 1 year ago #

    I tried to modify this: <?php for ($i = 1; $i <= 2; $i++)
    But putting 1 instead of 2, because I don't want a slider but it didn't work.
    Any other idea?
    Thanks.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags