Hi everyone,
im currently designing a website for a hotel. I have a 'special offers' page and im trying to call the latest offer and show it on the home page. Iv got it working with the script below but my problem is its pulling every offer and i cant work out how to only pull the first element.
Home page
- http://garracktemp.c....com/index.html
Offers page
- http://garracktemp.c...ial-offers.html
$(document).ready(function(){
$('#test').load('/Garrack_Hotel/special-offers.html .offer_info_content', '', function(response, status, xhr) {
if (status == 'error') {
var msg = "Sorry but there was an error: ";
$(".content").html(msg + xhr.status + " " + xhr.statusText);
}
});
});
any help with this would be great as im still getting to grips with js and azax
Register and join over 40,000 other developers!
Recent Topics
-
The Game You Are Waiting For?
WendellHarper - Dec 06 2020 01:21 PM
-
Quora and Reddit Backlinks
WendellHarper - Dec 06 2020 01:14 PM
-
Delete account
pindo - Jul 23 2020 01:33 AM
-
Print specific values from dictionary with a specific key name
Siten0308 - Jun 20 2019 01:43 PM
-
Learn algorithms and programming concepts
johnnylo - Apr 23 2019 07:49 AM
Recent Blog Entries
Recent Status Updates
Popular Tags
- networking
- Managed C++
- stream
- console
- database
- authentication
- Visual Basic 4 / 5 / 6
- session
- Connection
- asp.net
- import
- syntax
- hardware
- html5
- array
- mysql
- java
- php
- c++
- string
- C#
- html
- loop
- timer
- jquery
- ajax
- javascript
- programming
- android
- css
- assembly
- c
- form
- vb.net
- xml
- linked list
- login
- encryption
- pseudocode
- calculator
- sql
- python
- setup
- help
- game
- combobox
- binary
- hello world
- grid
- innerHTML

using Ajax & Jquery to call first class
Started by JamesHusband, Sep 09 2012 12:52 AM
jQuery ajax jquery
No replies to this topic
#1
Posted 09 September 2012 - 12:52 AM
Also tagged with one or more of these keywords: jQuery, ajax, jquery
Language Forums →
HTML, CSS and Javascript →
Jquery .hasClass not returning true for a classnameStarted by Wackostylee, 13 Oct 2018 ![]() |
|
![]() |
||
Language Forums →
Other Languages →
ASP, ASP.NET and Coldfusion →
Dynamic controls and asp:button postbackStarted by Tchpowdog, 12 Jun 2016 ![]() |
|
![]() |
||
Language Forums →
HTML, CSS and Javascript →
Syntax and Reference Error?Started by Tonyobyo, 10 Jun 2016 ![]() |
|
![]() |
||
Language Forums →
HTML, CSS and Javascript →
Redirect after successful data post in AjaxStarted by PuddingEatsPanda, 16 Feb 2016 ![]() |
|
![]() |
||
Language Forums →
HTML, CSS and Javascript →
JQuery/NodeJS AJAX Response HelpStarted by Poe, 27 Jan 2016 ![]() |
|
![]() |
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download