Make WordPress Core

Opened 19 years ago

Closed 19 years ago

Last modified 18 years ago

#1491 closed enhancement (fixed)

Adding CURL support to /wp-admin/link-import.php

Reported by: cypher's profile Cypher Owned by: markjaquith's profile markjaquith
Milestone: Priority: normal
Severity: normal Version: 1.5.1.2
Component: Administration Keywords: CURL link import bg|has-patch bg|commit
Focuses: Cc:

Description

The current link-import.php file assumes that remote FOPEN() is available to read OPML files. This patch adds a check for allow_url_fopen and in the case of it not being available, uses CURL to grab the file.

Attachments (2)

link-import.diff (934 bytes) - added by Cypher 19 years ago.
Link-import diff
link-import.2.diff (507 bytes) - added by davidhouse 19 years ago.

Download all attachments as: .zip

Change History (7)

@Cypher
19 years ago

Link-import diff

#1 @markjaquith
19 years ago

  • Keywords bg|2nd-opinion added
  • Milestone set to 1.6

I'm starting to think that it would be good to have all the remote file fetching be done by our own class/function that can figure out if fopen(), CURL, or Snoopy is the best choice. It seems that each one is being done its own way. Why not just a generic

$file = wp_get_remote_file($uri);

??

#2 @davidhouse
19 years ago

  • Keywords bg|has-patch added

We already have wp_remote_fopen() in functions.php which returns the contents of a remote file. I attached a patch which takes advantage of said function.

#3 @markjaquith
19 years ago

  • Keywords bg|commit added; bg|2nd-opinion removed
  • Owner changed from anonymous to markjaquith
  • Status changed from new to assigned

#4 @ryan
19 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [2854]) Use wp_remote_fopen to fetch remote OPML. Props Cypher, davidhouse. fixes #1491

#5 @(none)
18 years ago

  • Milestone 2.0 deleted

Milestone 2.0 deleted

Note: See TracTickets for help on using tickets.