Jump to content
  • 0

xml + php


drew
 Share

Question

Добрый день!

Посматривал тут, что можно сделать интересного с помощью xml и php, и решил быстренько попробовать набросать маленькую гостевую книгу, или что-то подобное, что бы можно было оставить коммент, да имя.

Вроде всё просто:

xml файл:

  Reveal hidden contents

index.php файл

  Reveal hidden contents

del_comment.php файл:

  Reveal hidden contents

и на всякий случай add_comment.php файл:

  Reveal hidden contents

Всё делалось на скорую руку, так что код конечно оставляет желать лучшего, но зациклившись на ошибке при удалении, я пока оставил работу над всей красотой. Буду мегапризнателен, если кто подскажет или натолкнёт на мысль, где у меня ошибка!

всё пока тестится тут: тут

Edited by drew
Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0
  Quote
<a href=\"del_comment.php?id=$id[$i]\">

значение нода id в index.php и номер в массиве one_com при удалении могут быть различными. При удалении нужно искать запись у которого нод id равен тому что передано по гет.

Link to comment
Share on other sites

  • 0
  On 11/5/2011 at 3:28 PM, xPoint said:
  Quote
<a href=\"del_comment.php?id=$id[$i]\">

значение нода id в index.php и номер в массиве one_com при удалении могут быть различными. При удалении нужно искать запись у которого нод id равен тому что передано по гет.

Спасибо, что-то тормознул :) Теперь всё хорошо работает :)

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.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   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.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. See more about our Guidelines and Privacy Policy