Forum Replies Created

Viewing 11 replies - 1 through 11 (of 11 total)
  • I don’t see this is a server problem – before a post is published, trying to open that post is going to give you a response of 404 rather than 200, no matter what you do.

    The only workaround as it stands is to publish a post before you can use multiple content blocks on that page. This should be fine for pages, where in most cases they won’t appear in a site’s navigation until you add them to menus (unless those menus automatically add top-level pages), but it’s a problem for any custom post types or even normal posts which populate lists the minute they’re published. Add in RSS and so on and you’ve got real problems where you have to publish unfinished content and broadcast it before it’s done.

    To fix this, I can see a couple of possible options:
    1. Write in a fallback function which uses file_get_contents, fopen() or similar to read the template files to check for occurrences of the the_block or get_the_block functions. Grab the name and create the custom post meta. HOWEVER this relies on knowing the file name of the template you’re supposed to be reading – you can go through the usual page, single, post etc but it’s more than likely you’ll miss some.
    2. Add an admin menu where you name your extra blocks up front as well as in your template files.

    The other option is to put the custom post meta in your theme files and add content blocks yourself rather than using this plugin.

    I may have missed something, however, and I’m happy to be corrected!

    Plugin Author maltpress

    (@maltpress)

    Hi Milan,

    Thanks for this – development stalled a little as I’ve been busy on paid work! However I will be doing some work on the plugin soon, and I like your ideas. I’ll see what I can do.

    Adam

    Plugin Author maltpress

    (@maltpress)

    Do you have a link so I can take a look?

    It’s possible that you’ll need to add something like this to the CSS (not in line, it’ll need to be in the header)…

    .pr_single_story {
       display: none;
    }

    …but I’ll need to take a quick look to confirm that.

    Sorry for the delayed reply, by the way!

    Forum: Plugins
    In reply to: Scrollarama CSS Hack

    Yep; the default is a blank box, and this hack is perfect for setting your own default background image.

    Background images are generated EITHER from a custom field called “slider” which takes an image url, or if that isn’t present, from the first attachment on a post. If this attachment is a media file rather than an image, it won’t work.

    Using the “slider” custom field is always the best way to add your image as it’s far easier to control without affecting the image on the post.

    Plugin Author maltpress

    (@maltpress)

    Nope – it’s just the closest I can find in the US to Mind, a UK charity I really believe in. But like I say – any charity you believe in would be cool.

    Plugin Author maltpress

    (@maltpress)

    OK – try this:

    Donate link

    Or failing that, the donate link on the right of the plugin home page… or failing that(!) or if you’d rather, give your donation to Mental Health America (NMHA) or a local mental health charity. Or any charity you believe in.

    Cheers

    Adam

    Plugin Author maltpress

    (@maltpress)

    Hi,

    This isn’t something I thought of doing – to be honest I wrote the plugin for a site I was working on and thought I’d release it into the wider world if anyone else needed it, so it kind of just does what I needed it to at the moment!

    You can do it yourself if you want to play with the code, though – it should be reasonably easy to get it doing what you want.

    There are two functions in scrollarama.php you’ll need to amend; pr_determineBackground(); on line 39 and pr_showPosts(); on line 95.

    The first, pr_determineBackground(); looks at whether a post has an attachment or something in the “slider” custom field; if it does, it creates a string called $background which has the CSS for the image, for example if it’s from the “slider” custom field:

    $background = "url(" . get_post_meta($looped_ID, 'slider', true) . ") center no-repeat;";

    You can change this to output <img> tags:

    $background = "<img src='" . get_post_meta($looped_ID, 'slider', true) . "' />";

    The pr_showPosts(); function is what creates the little loop to show the posts; amend this to call the pr_determineBackground(); function when you want to output your image, and change any css classes etc as you see fit. As long as this loop is within the div with the class pr_side_slider the cycle should work.

    Hope this helps!

    Plugin Author maltpress

    (@maltpress)

    Hi,

    The only way to do this is to make images which are the right size and add them using custom fields:

    • Edit the post to add the image to
    • Add a custom field called “slider”
    • Use the path to an image for the custom field value. This can be one in your media library or use an absolute path from another site if you have permission to do so.

    Background image resizing using CSS3 isn’t particularly well supported yet, and it gets pretty complex to create something which could theoretically be any size but which can handle different image sizes. I’ve tried to make it so that you’ve got that extra little bit of flexibility in that you can use attachments automatically (which might give you nice, if a little offset, images) or add your own.

    You’re not doing anything wrong with the Cycle Options, it’s just that the way this is written (using the image you set as a background) “Fit” won’t make any real difference.

    I’ll take a look at making this a bit more intuitive in the next version, which will address some of the layout and styling questions I’ve been having.

    Thanks for using the plugin!

    Adam

    Plugin Author maltpress

    (@maltpress)

    No navigation at the moment – that’s starting to add a new level of complexity. It’ll happen one day, I’m sure, but probably not for a while I’m afraid (I have to do some paid work now!).

    This might be a bit more what you’re after:
    https://www.ads-software.com/extend/plugins/featured-posts-slideshow/screenshots/ but it may need a bit of work as it’s not been updated for a while.

    If you would like to donate, Here’s the link – much appreciated!

    Adam

    Plugin Author maltpress

    (@maltpress)

    Hey FlashBuddy,

    New version now available lets you change the plugin speed – both how long the slides show, and how quickly the transition takes place.

    Any more requests (or ideas for other plugins!) let me know…

    Plugin Author maltpress

    (@maltpress)

    Hey,

    Thanks for the kind words!

    Transition speed is set at the moment and that’s certainly something I’ll change in the next version (hopefully I’ll be able to work on it next week).

    In the mean time, if you’re reasonably confident making changes to the plugin files (you can do this offline and then upload, or do it through the plugin editor if the files are writeable) you can change the speed like this:

    Go to line 168 and edit it so it reads:

    echo "fx: '" . $pr_effects . "',";

    All I’ve added here is a comma at the end, after the single quote. Then insert a new line.
    On the new line, add the following:

    echo "timeout: 3000";

    Where the number is the time between slides in milliseconds.

    You can add other jQuery Cycle attributes in the same way – for example, to set the speed of the transition (i.e. how fast the fade is, rather than how long there is between fades) add the following line:

    echo "speed: 300";

    You will need to make sure that if you add more than one setting, all but the last must end with a comma (i.e. echo "timeout: 3000,";

    Hope that helps – like I say, next version will include timeout, plus I’ll include speed, and an advanced field to add your own Cycle attributes.

Viewing 11 replies - 1 through 11 (of 11 total)