Welcome, Guest. Please login or register.
Did you miss your activation email?
February 12, 2012, 04:05:11 AM

Login with username, password and session length
Search:     Advanced search
Wollen Sie dem WebsiteBaker Team beitreten?
Nähere Informationen finden Sie unter hier und auf unserer neuen Webseite.
149621 Posts in 21098 Topics by 7537 Members
Latest Member: lotte2
* Home Help Search Login Register
Pages: 1 ... 5 6 [7] 8 9 ... 21   Go Down
Print
Author Topic: Code Snippet: Display news items, anywhere  (Read 100197 times)
babsy

Offline Offline

Posts: 311


« Reply #150 on: June 02, 2008, 08:46:35 AM »

Hi, has anyone a solution for the bottom line, it "jumbs around", my client has to press enter until its below the text... Is there a way to make it automatic going to the bottom Smiley  huh without using enter Smiley huh
Logged
Olli

Offline Offline

Posts: 288


« Reply #151 on: June 02, 2008, 09:15:16 PM »

Hi, has anyone a solution for the bottom line, it "jumbs around", my client has to press enter until its below the text... Is there a way to make it automatic going to the bottom Smiley  huh without using enter Smiley huh

i'm not quite sure what you mean. please tell a bit more about your problem. i'm sure there is a solution - does not sound that spectacular wink

regards
Logged
babsy

Offline Offline

Posts: 311


« Reply #152 on: June 03, 2008, 09:01:59 AM »

hi... if you look at www.vagaportal.com in IE, and then look at it in Firefox, you will see what i mean... it´s the bottom line, that is between the news..  smiley
Logged
marathoner

Offline Offline

Posts: 495


« Reply #153 on: June 03, 2008, 02:47:02 PM »

Display differences between browsers is, um, a browser issue and not an issue with the Anynews module. Simply play with your CSS to achieve the desired results. I would guess that this is related to float (or in your case image align since you didn't use float). I also noticed a bunch of empty DIV's in the news item that doesn't display the HR correctly.
Logged
babsy

Offline Offline

Posts: 311


« Reply #154 on: June 03, 2008, 03:19:08 PM »

hi... ok, thanks.. for your help... i´m going to try to make it look good Smiley
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #155 on: July 07, 2008, 04:18:37 PM »

For all WB2.7 users of any_news..

I modified the snippet so it now respects start and end dates of the posts.
The modification was done because someone had a problem with posts being showed where they should not be showed anymore. http://www.websitebaker2.org/forum/index.php/topic,10233.msg60019.html#msg60019

The solution tests for the WB version, and is compatible with the WB 2.6.7 version.

Cheers,

Ruud

EDIT: Attachment removed. Newer version available through addons repository.

« Last Edit: October 20, 2008, 01:37:52 PM by Ruud » Logged

Professional WebsiteBaker Developer
doc
Guest
« Reply #156 on: July 07, 2008, 04:22:14 PM »

Thanks, a bugfix was already postet in reply #142 of this thread. Will add a working solution to the addons repository if my time allows to do it.

Regards Christian
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #157 on: July 07, 2008, 04:30:09 PM »

That's fine Christian.

The fix you referred cannot be used in 2.6.7 sites, so you cannot use this in a download version.
My version will do the same (ofcourse), but only when > 2.7 is used. 2.6.x will use the old query.

Just have a look at it when you have got time.

Cheers,

Ruud
Logged

Professional WebsiteBaker Developer
doc
Guest
« Reply #158 on: July 07, 2008, 07:21:02 PM »

Hello Ruud,

I know about the short comings of the version I posted.

Unfortunatelly there is a bug in the news module of WB 2.7, which needs an additional workaround to get anynews working with 2.6.x, 2.7 RC1 to final and any future 2.7.x.

Therefore no update of the anynews snippet is available so far on the addons repository. Best thing would be to check for database fields instead of version numbers to make sure anynews works on all platforms. Will have a closer look on this issue once time does free up in the future.

Regards Christian
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #159 on: July 25, 2008, 08:52:46 PM »

Despite the existing bug and workaround that might be needed, I made a small modification in the last version.

In this post the problem was reported there is no translation for internal links in the snippet.

In this version (v0.14) this is fixed.

Ruud

EDIT: Attachment removed. Newer version available through addons repository.
« Last Edit: October 20, 2008, 01:38:18 PM by Ruud » Logged

Professional WebsiteBaker Developer
DarkMaster3960

Offline Offline

Posts: 15


« Reply #160 on: July 29, 2008, 09:05:08 AM »

Heya,

ok, its early morning and it was a very sleepless night, so please excuse my question, but i dont know where or how to add news with this very nice snipped.

So far ive added a custom code to one of my pages but theres always shown: there are no news available yet.

And are there any options in the backend where i could change anything?

Thanks for your help...
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #161 on: July 29, 2008, 09:14:09 AM »

First create a news page (you can hide from the menu if you want).
In there you can create the news items. AnyNews will see the created items automatically.

Ruud
Logged

Professional WebsiteBaker Developer
DarkMaster3960

Offline Offline

Posts: 15


« Reply #162 on: July 29, 2008, 09:19:02 AM »

thanks, but

if i use a code page, how can i create news items there? i thought it uses the database for news?
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #163 on: July 29, 2008, 09:24:20 AM »

You don't need to create the news-page in the same place.

You need a page (anywhere) to input (and display the full article).
The AnyNews snippet could be used in a code-section (if you need it on a single page) or in your template/index.php (if you need it on every page).

Ruud
Logged

Professional WebsiteBaker Developer
DarkMaster3960

Offline Offline

Posts: 15


« Reply #164 on: July 29, 2008, 09:29:48 AM »

ok, i think ive understod but could you give me an example please?

Thanks a lot, i think any news is exactly what i looked for...  grin
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #165 on: July 29, 2008, 09:39:16 AM »

Please have a look here:
WebsiteBaker Help Project - News

That will help creating a news page.

Ruud
Logged

Professional WebsiteBaker Developer
DarkMaster3960

Offline Offline

Posts: 15


« Reply #166 on: July 29, 2008, 09:46:35 AM »

Ohhhh I LOVE YOU!!!

Its so weird, it was right in front of me and i didnt see this... ahh awfull...
everything i need is already integrated in WebsiteBaker and is didnt see this...

Cruel world...

ARGH, im so sorry that is wasted your time with this kiddies***...
but, just as i said, its early in the morning and the first walk i made was to the computer and straight into this forum. as i got up this morning i thought i had THE idea...

Ok, remember, first FAQ then google, then the forumsearch and then POST...

Thank you... -.-'
Logged
babsy

Offline Offline

Posts: 311


« Reply #167 on: August 01, 2008, 09:24:39 PM »

hi, i know i have asked about this before, but i have tried to change the css anyway i know, but i still can´t get the line between the news to show right (i still have to make "enter" until it´s below the image i use, and then the "read more" text goes to far down, looks a bit weird!...

is there anyone who can help me in the right direction with this... or tell me where to change it! i have tried to change the css file... but no luck there, Huh? afro
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #168 on: August 01, 2008, 09:39:47 PM »

is there anyone who can help me in the right direction with this... or tell me where to change it!

Can we have a look somewhere?

Ruud
Logged

Professional WebsiteBaker Developer
babsy

Offline Offline

Posts: 311


« Reply #169 on: August 01, 2008, 09:49:44 PM »

www.hfhmagazine.com

my problem is the anynews " on the left", when i use pictures in the short text!!, you see the second, third nr. news and so on, i have used "enter" to regulate is, but it does not look good, i want the ...read more, to come right after the text and even if i use a big picture i want the line (hr) to come at the bottom, not to the right (even if i choose "left" in the picture edit)!!

hobe you know what i mean, i know this is css question, but i just can´t figure it out??!!
« Last Edit: August 01, 2008, 09:58:35 PM by babsy » Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #170 on: August 01, 2008, 10:01:43 PM »

Try adding
Code:
#mynews p {
overflow:auto;
}

Is that what you want?

Ruud
Logged

Professional WebsiteBaker Developer
babsy

Offline Offline

Posts: 311


« Reply #171 on: August 01, 2008, 10:08:17 PM »

yesssssssssssssss thank you thank you thank you, thats just what i have been looking for Smiley

ubs, exept i wanted the "read more" to be at the end of the text,... but this is still much better  Smiley then before!
« Last Edit: August 01, 2008, 10:11:27 PM by babsy » Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #172 on: August 01, 2008, 10:20:46 PM »

A bit risky.. but looks good

Code:
#mynews h2 {
  text-align: right;
  margin-top: -20px;
}

Ruud
Logged

Professional WebsiteBaker Developer
babsy

Offline Offline

Posts: 311


« Reply #173 on: August 03, 2008, 12:59:12 PM »

now its perfect, thanks for your help Smiley

i read in the thread that someone had found out how to show the date (posted when) with the anynews! but i can´t find the code for that in the forum, can anyone point me to the post for that?
Logged
Ruud
Board member
WebsiteBaker Org e.V.

Offline Offline

Posts: 2093



WWW
« Reply #174 on: August 03, 2008, 03:16:49 PM »

In the AnyNews "include.php" find the line:

Code:
// OUTPUT NEWS ITEMS WITH NEWS TITLE, SHORT NEWS TEXT AND READ MORE LINK

Below that line the output is created.
Depending on the location where you need the date/time to appear you could add:

Code:
$output .= "<p class=\"dateformat\">".gmdate("d M Y, H:i", $data['posted_when']+TIMEZONE)."</p>\n";
(class "dateformat" is added so you can use CSS to position and size things.)

Cheers,

Ruud
Logged

Professional WebsiteBaker Developer
Pages: 1 ... 5 6 [7] 8 9 ... 21   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!