Results 1 to 2 of 2

Thread: How to view web content by php

  1. #1


    คือตอนนี้ผมกำลังหัดเขียน php อยู่ (หัดเขียนเลยนะ) คราวนี้สิ่งที่ต้องการคือ ต้องการ html sourcecode ของ webpage ไม่ทราบว่าจะทำได้อย่างไรครับ

    ตัวอย่างเช่น
    input = http://citec.us/forum/index.php
    output จะต้องได้เป็น html sourcecode เหมือนตอนเรากด คลิกขวา view sourcecode

    ปล. เอาแบบง่ายๆ ก็ดีครับ ผมใหม่กับ php จริงๆ

  2. #2
    Jedi Global Moderator Gen0TypE's Avatar
    Join Date
    Jan 2008
    Location
    Khonkaen
    Posts
    312


    ปกติแล้ว php version ใหม่ๆ จะไม่อนุญาติให้อ่าน content ของไฟล์ที่อยู่คนละ domain นะครับ

    แต่เราสามารถปรับได้ที่ไฟล์ php.ini
    **Hidden Content: To see this hidden content your post count must be 5 or greater.**

    ไม่งั้นจะเจอ error ประมาณนี้
    Code:
    URL file-access is disabled in the server configuration in 'filename' on line 3

    ส่วน code php ที่ใช้อ่าน content ก็มีดังนี้ครับ
    **Hidden Content: To see this hidden content your post count must be 5 or greater.**

Similar Threads

  1. YouTube Hack Allows Users To View Deleted Content
    By newsbot in forum World Hacking/Security News
    Replies: 0
    Last Post: 26-12-2007, 08:59 PM
  2. Replies: 0
    Last Post: 19-05-2007, 04:06 PM
  3. Read content from File
    By asylu3 in forum Perl
    Replies: 0
    Last Post: 30-06-2006, 01:23 PM
  4. How to search content with in a file.
    By asylu3 in forum Operating System, Server and Networking
    Replies: 0
    Last Post: 06-02-2004, 06:47 AM

Members who have read this thread : 0

Actions : (View-Readers)

There are no names to display.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •