1
council
Php and CSS in a Box
  • 2005/1/19 12:02

  • council

  • Not too shy to talk

  • Posts: 184

  • Since: 2004/12/18


Hi,

I've got xmline working and now I want to add images and css to the custom box I've got it in.

How do I do this?

What I mean is, the contents of the box is now an include code and the box is set for php script.

R.

2
Herko
Re: Php and CSS in a Box
  • 2005/1/19 12:13

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


then the output is created and comntrolled by the script you've included, you have to edit the script to include your own output (any css/html is output in this case)

Herko

3
council
Re: Php and CSS in a Box
  • 2005/1/19 13:10

  • council

  • Not too shy to talk

  • Posts: 184

  • Since: 2004/12/18


Quote:

Herko Coomans wrote:
then the output is created and comntrolled by the script you've included, you have to edit the script to include your own output (any css/html is output in this case)

Herko



The "script" is the drop-down choice offered when you create a custom box. I chose php instead of html.

If you're saying I must edit this script, where's it at?

Also, if it's a php script, how do I include html in it?

r.

4
Herko
Re: Php and CSS in a Box
  • 2005/1/19 13:15

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


ok, Ill try again then

You say you have created a new custom block, type PHP, and used some PHP code to include a PHP script that generates a specific output, right? And that you want to add images and CSS styles to that output.

Images and CSS need to be added to the HTML code that is generated by the PHP script you've included in your custom block. Therefore, in order to do that, you have to make sure that the PHP script actually creates the HTML and CSS code you want it to generate. Thus, you need to edit the outup part of the PHP script you've included in your block, adding the HTML (image tags and sources) and CSS (class calls) to the output generating code.

Does this make more sense to you? If not, I'll ask someone else to tell it better

Herko

*heh, you edited your post...
What is the contents of the custom block, exactly?

Herko(2)

5
council
Re: Php and CSS in a Box
  • 2005/1/19 13:23

  • council

  • Not too shy to talk

  • Posts: 184

  • Since: 2004/12/18


Quote:

Herko Coomans wrote:
ok, Ill try again then

You say you have created a new custom block, type PHP, and used some PHP code to include a PHP script that generates a specific output, right? And that you want to add images and CSS styles to that output.

Images and CSS need to be added to the HTML code that is generated by the PHP script you've included in your custom block. Therefore, in order to do that, you have to make sure that the PHP script actually creates the HTML and CSS code you want it to generate. Thus, you need to edit the outup part of the PHP script you've included in your block, adding the HTML (image tags and sources) and CSS (class calls) to the output generating code.

Does this make more sense to you? If not, I'll ask someone else to tell it better

Herko

*heh, you edited your post...
What is the contents of the custom block, exactly?

Herko(2)



Thanks for your time, Herk. Here's the php code:

include_once(XOOPS_ROOT_PATH . '/modules/xmline/blocks/xmline_blocks.php');
$options = "20|1|300";
b_xmline_custom($options);


Now what I want to do is add an image and nice it up with some css.

R.

6
council
Re: Php and CSS in a Box
  • 2005/1/19 13:40

  • council

  • Not too shy to talk

  • Posts: 184

  • Since: 2004/12/18


Quote:
Thus, you need to edit the outup part of the PHP script you've included in your block, adding the HTML (image tags and sources) and CSS (class calls) to the output generating code.
--Herko


Let me see if I understand you...

the output generated by the php in the box was a rss feed. It's four lines of text. Are you saying I must take this text and add html and css to it in order to get it to disply what I want?

If so, my question is how will this affect the automatic updating of the feed? The php code was generated by xmline. Won't I be corrupting it?

r.

7
Herko
Re: Php and CSS in a Box
  • 2005/1/19 13:45

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


no, you'll have to edit the /modules/xmline/blocks/xmline_blocks.php file. but it all depends on where you want to add styles and images.

herko

8
council
Re: Php and CSS in a Box
  • 2005/1/19 15:07

  • council

  • Not too shy to talk

  • Posts: 184

  • Since: 2004/12/18


Quote:

Herko Coomans wrote:
no, you'll have to edit the /modules/xmline/blocks/xmline_blocks.php file. but it all depends on where you want to add styles and images.

herko


What I'm trying to do is to have about 10 custom boxes on my front page. Each of these boxes would contain a seperate rss/xmline feed that updates automatically.

Also, each of these boxes will contain an image.

Also, each of these boxes will be css styled.

How do I do that?

Login

Who's Online

343 user(s) are online (276 user(s) are browsing Support Forums)


Members: 0


Guests: 343


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits