Jump to content
php.lv forumi

nevaru lidz galam izdomat


dAivEd

Recommended Posts

Ir tabulas

`forum` -> (id,name) // GALVENAS KATEGORIJAS

 

Ir Subkategorijas

 

`forum_cats` -> (id,category_id,subcategory_name); // SUB KATEGORIJAS

 

 

Ir topiki

 

`forum_theads` -> (id,subcat_id,thead_name,autor,last_post,text); // PASHA TEEMA

 

 

Ir ta saucami posti

 

 

`forum_posts` -> (id,topic_id,post_test,date,ip); // PASHI POSTI PIE KATRAS TEEMAS

 

 

sanaak ta

 

 

- DOMAIN.LV // KATEGORIJA NO ( forum )

 

-- Ieteikumi // SUBKATEGORIJA NO ( forum_cats ) -> tur ieksha uzklikskinot ir teemas

 

-- Helps / Shits // SUBKATEGORIJA NO ( forum_cats ) -> tur ieksha uzklikskinot ir teemas

 

 

Vajag savakt cik kopa posti ir ieksh katras sub kategorijas

 

Kads var palidzet ? Ja kautkas nav saprotams rakstat!

Link to comment
Share on other sites

Ne es izmantoju ta teikt savu pashrakstito

 

 

Un par tavu ideju arii ta domaju

Sanaca uztaisit ta ka ieksh katras subkategorijas uzreiz ierakstas kursh pedejais iepostoja un laiku un ieksh kadas sadaljas, bet man liekas postus ta nesanaks

Link to comment
Share on other sites

Kapēc gan nē? Vakar rakstīju bilžu galeriju tur sanāca mazāk tabeli vienīgi ,bet princips tad tas pats.

 

user >
    gallery >
            bildes >
            mysql_query('update gallery set coments = coments + 1 where id = '.$id.';');
            mysql_query('update user set coments = coments + 1 where id = '.$user.';');

 

Un dzēšot atkal otrādi -1

Link to comment
Share on other sites

Ja bet problema taaada ka man taja foruma ieksh kategorijam jau ir 1k + posti vai pat vairak. ta jau es biju domajis tavu ideju.. man tagad vajag taisit vai arii atsevishko skriptu kursh updeito aili count_posts ikehs `cats` saskaitot visus postus, bet reali tas jau bus taspats ko gribu uztaisit tagad forumam.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...