Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8077223
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T15:25:46+00:00 2026-06-05T15:25:46+00:00

I am building a wordpress site using jQuery with cycle plugin to cycle through

  • 0

I am building a wordpress site using jQuery with cycle plugin to cycle through some posts.

I have an image used as a full background, with this css:

  img.bg {
        /* Set rules to fill background */
        min-height: 100%;
        min-width: 1024px;

        /* Set up proportionate scaling */
        width: 100%;
        height: auto;

        /* Set up positioning */
        position: fixed;
        top: 0;
        left: 0;
    }

    @media screen and (max-width: 1024px){
        img.bg {
            left: 50%;
            margin-left: -512px; }
    }

I have inserted the first image attachment url into the img.bg with a javascript from the loop. However, this understandably only works once, at page load.

This is the javascript:

$(function () {
$('.bg').attr('src', '<?php get_image_url(); ?>');
});

What I need, I guess is to fire off the script with each iteration of the cycle script, because the source shows that the get_image_url() function supplies the script with the unique url in each article div.
In the end, I even want some navigation buttons to move back and forth, switching the posts and the background simultanuously.

Any suggestions?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T15:25:47+00:00Added an answer on June 5, 2026 at 3:25 pm

    As for now, I use $(".bg").prependTo(document.body); to get the background images out of the article div, and then starting the cycle. This works, although some more problems might mount on the way.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building a Wordpress site using Sencha Touch. I've created a plugin that converts
I'm currently building an e-commerce site in wordpress using the WP-ecommerce plugin.In product page,
I am using wordpress as a full on CMS on a site I am
I'm building a WordPress based AJAX site, where I use jQuery and the .get()
I'm building a WordPress plugin using PHPExcel to export reports of student attendance. So
I have jQuery for a WordPress theme I'm building. I've given up for now
I'm building a filter plugin in Wordpress and I'm replacing some plugin specific tags
I have a site that i am building that mixes wordpress and my own
i'm building a wordpress webpage based on the Skeleton Wordpress theme. I have 2
I am using wordpress as my cms and building a website. I use Graphene

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.