Author Topic: Best way to store blog posts  (Read 11307 times)

0 Members and 1 Guest are viewing this topic.

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: Best way to store blog posts
« Reply #15 on: February 26, 2014, 04:46:40 pm »
Code: [Select]
<?php
session_start
();
$_SESSION['lose'] = 'THE GAME';
echo 
$_SESSION['lose'];
?>
Does that help your memory? ;)

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: Best way to store blog posts
« Reply #16 on: February 27, 2014, 04:04:31 am »
Well thanks for the discussion, I forgot that $_SESSION was actually stored server-side and not sent as _GET and _POST. I'll to redesign a lot of things! (Better posting implmentation yay!)

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: Best way to store blog posts
« Reply #17 on: February 27, 2014, 07:34:21 am »
there is also $_COOKIE for cookies, $_SERVER for information about the current instance (like remote IP), and $_REQUEST which is $_GET $_POST and $_COOKIE combined.
Might have missed some >.<

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: Best way to store blog posts
« Reply #18 on: March 12, 2014, 06:03:19 pm »
Welp, if you want to get some news about my battle against PHP, it seems my project is working nicely at the moment. I'm still working between refactors and database redisign, but it's still fine.
For the moment.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Best way to store blog posts
« Reply #19 on: March 12, 2014, 11:17:35 pm »
Looks kinda nice so far :D

However, on some monitors and contrasts, it might be hard to see the divs colors and stuff since everything will just look like black.

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: Best way to store blog posts
« Reply #20 on: March 13, 2014, 06:18:04 am »
Yeah, on my phone the red looks black. But if I choose brighter colors, I think that'll make it ugly. I'll to remake my color swatches.
The R-A logo will change, it never looked in place with the blog anyway. One graphical change to do too. I don't know how it'll look after then.

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: Best way to store blog posts
« Reply #21 on: March 13, 2014, 09:41:27 am »
Looking nice, gladwe could help you out some :)

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: Best way to store blog posts
« Reply #22 on: March 14, 2014, 09:10:12 am »
If you want to help me more, I woul'd be glad. i'm far from having finished it! ^^


EDIT : With your class, Joins doens't work at all...
Code: [Select]
res = $sql->query("SELECT `B.bi, `B.bn`, `B.bs` ".
   "FROM `Blah B` LEFT JOIN `Ah_Blah` A ON A.bi = B.bi ".
        "WHERE A.ai = `%s`;", [$_SESSION['ui']]);
it only works without `quoting`


EDIT : Nailed it
Code: [Select]
res = $sql->query("SELECT `B`.`bi`, `B`.`bn`, `B`.`bs` ".
   "FROM `Blah` B LEFT JOIN `Ah_Blah` A ON `A`.`bi` = `B`.`bi` ".
        "WHERE `A`.`ai` = %d;", [$_SESSION['ui']]);
« Last Edit: March 14, 2014, 09:20:22 am by Eiyeron »

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: Best way to store blog posts
« Reply #23 on: March 17, 2014, 05:24:43 pm »
As it is SQL you don't need to join, it doesn't care about line breaks and weird tabs ;)

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Eeems

  • Mr. Dictator
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6268
  • Rating: +318/-36
  • little oof
    • View Profile
    • Eeems
Re: Best way to store blog posts
« Reply #24 on: March 17, 2014, 08:14:54 pm »
As it is SQL you don't need to join, it doesn't care about line breaks and weird tabs ;)
Explicit joins are preferable in sql though. Implicit joins can be slower.
/e

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: Best way to store blog posts
« Reply #25 on: March 18, 2014, 03:31:33 am »
As it is SQL you don't need to join, it doesn't care about line breaks and weird tabs ;)
Yeah, I know for tabs, I made it readable after it worked.