mIRC Home    About    Download    Register    News    Help

Print Thread
html question #204838 03/10/08 09:21 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
I know this arent a mirc related question, but can't hurt to ask anyway wink

Someone that know how i can get a line to appear in the left bottom corner in a .html file? the text i trying to get there are this one:

<p align="left" style="margin-top: 0pt; margin-bottom: 0pt;"><font size="1">some text here </font></p>

i don't know how to solve that one, the margin-top dosent mather if it's renamed to margin-bottom , someone that know how i can solve it?


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204841 03/10/08 09:59 PM
Joined: Jun 2006
Posts: 508
D
deegee Offline
Fjord artisan
Offline
Fjord artisan
D
Joined: Jun 2006
Posts: 508
Like this perhaps?
Code:
  if $read(filename.html,w,*</body>*) {
    write -il $+ $readn filename.html <Your text to write>
  }

Re: html question [Re: deegee] #204863 04/10/08 08:24 AM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
That wasnt what i was looking for, so i skip that one for now, any ideas on how i can create a TABLE in a html file with diffrent amount of columns? i trying to create a statistics page, and i got the row's, thats a standard one, same amount of them every time, but the columns will store the information, so if it's 10 users on a channel i need 10 columns, if it's 3 users i only need 3, and since a channel can have up to 1000 users i need it to be set after the amount of users. I created a page with a table, but it dosent store the amount of colums as a number anywhere, ideas on this one? smirk

I use $nick($1,0) to get how many columns i need.


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204881 04/10/08 09:44 PM
Joined: Feb 2004
Posts: 206
D
Darwin_Koala Offline
Fjord artisan
Offline
Fjord artisan
D
Joined: Feb 2004
Posts: 206
Why not flip the table? It is easier to create rows than create columns? Some psuedo code (for columns):

Code:
for each row_element
  set_text "<tr><td>", Row_Name, "</td>"
  for each user_ID
    set_text original_text & "<td>", Relevant_Data, "</td>"
  next user_ID
  set_text original_text & "<tr>"
next row_element


Noting that "relevant data" has to be extracted from some matrix

the same code for rows:
Code:
  set_text "<tr><td>", Names/Stats, "</td>","<td>", Stat_Name1, "</td>", "<td>", Stat_Name2, "</td>", "<td>", Stat_Name3, "</td><tr>",
  for each user_ID
    set_text "<tr><td>", User_Name, "</td><td>", User_Stat1, "</td><td>", User_Stat2, "</td><td>", User_Stat3, "</td><tr>"
  next user_ID
next row_element


The use of ASP (or equivalent) code to extract the data from a data source (database) would be even easier because you can then do it on the fly!

Totally untested and straight off the top of my head, but some food for thought.

Cheers,
DK





Darwin_Koala

Junior Brat, In-no-cent(r)(tm) and original source of DK-itis!
Re: html question [Re: Darwin_Koala] #204882 04/10/08 09:55 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
That add the information for the users on the same row, i wanted to separate the info in a table (or something simulare), it looks clean and easy to read. it looks cluttered if it's on a single row.
Code:
<style type="text/css">
<!--
body,td,th {
	color: #FFFF00;
}
body {
	background-color: #000000;
}
-->
</style>
<div align="center">
  <p>&nbsp;</p>
  <p>Stats for #none</p>
  <table width="439" border="1" cellpadding="3">
    <tr>
      <td width="97"><div align="center">User nick </div></td>
      <td width="173"><div align="center">User host </div></td>
      <td width="135"><div align="center">User status</div></td>
    </tr>
    <tr>
      <td><div align="center">Nick1</div></td>
      <td><div align="center">some@host.com</div></td>
      <td><div align="center">Oped ( @ )</div></td>
    </tr>
    <tr>
      <td><div align="center">Nick2</div></td>
      <td><div align="center">another@host.com</div></td>
      <td> <div align="center">Normal </div></td>
    </tr>
  </table>
</div>

looks realy clean. Something like this, but i need to be able to set the info on how many fields are needed.


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204884 04/10/08 10:19 PM
Joined: Feb 2004
Posts: 206
D
Darwin_Koala Offline
Fjord artisan
Offline
Fjord artisan
D
Joined: Feb 2004
Posts: 206
My code is only pseudo-code to illustrate the concept of how it can be completed, not intended to working out of the box.

What you have listed is the results of my second suggestion (data in rows in a table, not columns). I made a slight error, my closing </TR> forgot the "/"! I didn't put the <table> commands in for simplicity.

The question is: are you using some code to develop a HTML file, which you then upload to the server? If you are trying to write this as a dynamic table, you need to look at server-side scripting, in which case your resulting code would have some similarities to my pseudo-code.

Cheers,

DK


Darwin_Koala

Junior Brat, In-no-cent(r)(tm) and original source of DK-itis!
Re: html question [Re: Darwin_Koala] #204887 04/10/08 10:25 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
This will only be local, so i don't upload it anywhere. i havent played around that much with html, only know the basic of it. tested what you wrote, coldent get it to look good. smirk


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204888 04/10/08 11:05 PM
Joined: Feb 2004
Posts: 206
D
Darwin_Koala Offline
Fjord artisan
Offline
Fjord artisan
D
Joined: Feb 2004
Posts: 206
Quote:
tested what you wrote, coldent get it to look good.


lol, that is because it is only pseudo-code. Add the table string at the front and end (like you have with yours), you could even separate the creation of relevant strings onto separate lines (adding cr/lf as necessary). No reason why it can't look as good!
But making it look good by using columns instead of rows is a little bit more work.

Cheers,

DK


Darwin_Koala

Junior Brat, In-no-cent(r)(tm) and original source of DK-itis!
Re: html question [Re: Darwin_Koala] #204897 05/10/08 09:20 AM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
can't get it to work as it should. smirk thnx anyway


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204901 05/10/08 04:57 PM
Joined: Jan 2003
Posts: 1,063
D
Doqnach Offline
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2003
Posts: 1,063
it's possible when working with either colspan/rowspan or tables in tables...


If it ain't broken, don't fix it!
Re: html question [Re: Doqnach] #204903 05/10/08 06:16 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
how come this one work?
Code:
<font size="2">I'm on Network: network - Server: <a href="irc://irc.server.com/testar">irc.server.com #testar</a><br>

and this arent?
Code:
<font size="2">I'm on Network: network - Server: <a href="irc://irc.server.com/#testar">irc.server.com #testar</a><br>

if i add the # sign it joins a channel called ##testar, and that's not right. removed the server i use cos it's my private, but put that in a html doc replace the server and test it, the last #testar with the # sign is only there for show. smile


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: html question [Re: sparta] #204912 05/10/08 09:22 PM
Joined: Dec 2002
Posts: 155
S
Strider Offline
Vogon poet
Offline
Vogon poet
S
Joined: Dec 2002
Posts: 155
Some of these generic HTML questions can be Googled with ease.

As for "irc://" hyperlinks, the "#" is a reserved character in URL's (as defined in RFC 3986), so I'm thinking that the best solution was to leave an implicit "#", instead of forcing everyone to use percent-encoding. Of course, there were losses: the "#" channel and local &channels are inaccessible due to this.