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 950603
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T23:35:36+00:00 2026-05-15T23:35:36+00:00

On this site , when user sets alarm sound and time, under Set Alarm,

  • 0

On this site, when user sets alarm sound and time, under “Set Alarm,” their chosen time and alarm sound appears.

I want instead of for example, 2:00pm [X] (alarm set – weather) or 2:00pm [X] (alarm set – rooster) I want the image of weather or rooster to appear instead of it printing text.

This is the function that is printing the text

function getAlarmName(ind){
    if(ind==4) return "weather";
    else if(ind==3) return "flight";
    else if(ind==1) return "time";
    else return "rooster";
}

I tried removing “weather,” and “flight,” for example and adding instead image/weather.jpg and image/flight.jpg, but that is not the correct syntax.

  • 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-05-15T23:35:37+00:00Added an answer on May 15, 2026 at 11:35 pm

    You could try this:

    function getAlarmName(ind){
        if(ind==4) return "<img src='image/weather.jpg' />";
        else if(ind==3) return "<img src='image/flight.jpg' />";
        else if(ind==1) return "<img src='image/time.jpg' />";
        else return "<img src='image/rooster.jpg' />";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is a question best illustrated by example: User goes to Site A ,
This is the standard scenario: User registers on the site User receives an account
I'm using the Google API to get a user's location on this site .
I'd like to use this method to create user-friendly URL. Because my site is
Got this site with UN/PW set via the Createuserwizard control. Client considers PW too
I have 3 sets of 4 input fields that I want the user to
As suggested by Chris, a user on this site. In the 1st perl script:
There are some sites that send parameters via URL like this: www.site.com/user/12345678 (just like
At this site I have a fixed nav and header when user clicks a
This site is pretty good but I'm wondering what other resources are out there.

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.