diff options
| author | lsces <lester@lsces.co.uk> | 2012-08-08 16:04:51 +0100 |
|---|---|---|
| committer | lsces <lester@lsces.co.uk> | 2012-08-08 16:04:51 +0100 |
| commit | 5f3d88cdb36cd7d80f291170ac7f69ce8bc1c155 (patch) | |
| tree | d9fcb1b857fa0732a931ba3ef745de8e2ff62ac4 | |
| parent | 6a6107f47020b443cb06817085a8f545d65622d2 (diff) | |
| download | articles-5f3d88cdb36cd7d80f291170ac7f69ce8bc1c155.tar.gz articles-5f3d88cdb36cd7d80f291170ac7f69ce8bc1c155.tar.bz2 articles-5f3d88cdb36cd7d80f291170ac7f69ce8bc1c155.zip | |
Should we be killing off the current process when a page redirect is actioned?
Edit's were saving, but not switching to the read view of the page.
| -rw-r--r-- | edit.php | 6 | ||||
| -rw-r--r-- | edit_topic.php | 1 | ||||
| -rw-r--r-- | index.php | 2 |
3 files changed, 5 insertions, 4 deletions
@@ -60,13 +60,13 @@ if( !empty( $_REQUEST['preview'] ) ) { if( !empty( $_REQUEST['save'] ) ) { if( empty( $_REQUEST['rating'] ) ) $_REQUEST['rating'] = 0; if( empty( $_REQUEST['topic_id'] ) ) $_REQUEST['topic_id'] = 0; - if( $gContent->store( $_REQUEST ) ) { if( isset ($gContent->mInfo['status_id']) and $gContent->mInfo['status_id'] == ARTICLE_STATUS_PENDING ) { - header ( "location: " . ARTICLES_PKG_URL. "index.php?feedback=".urlencode( tra( 'Your article has been submitted and is awaiting approval.' ) ) ); + header ( "Location: " . ARTICLES_PKG_URL. "index.php?feedback=".urlencode( tra( 'Your article has been submitted and is awaiting approval.' ) ) ); } else { - header ( "location: " . ARTICLES_PKG_URL . ( ($gBitSystem->isFeatureActive('pretty_urls_extended') || $gBitSystem->isFeatureActive('pretty_urls')) ? $gContent->mArticleId : "read.php?article_id=" . $gContent->mArticleId ) ); + header ( "Location: " . ARTICLES_PKG_URL . ( ($gBitSystem->isFeatureActive('pretty_urls_extended') || $gBitSystem->isFeatureActive('pretty_urls')) ? $gContent->mArticleId : "read.php?article_id=" . $gContent->mArticleId ) ); } + die; } } diff --git a/edit_topic.php b/edit_topic.php index b29b1fb..95b834b 100644 --- a/edit_topic.php +++ b/edit_topic.php @@ -31,6 +31,7 @@ if( isset( $_REQUEST["fSubmitSaveTopic"] ) ) { $gContent->storeTopic( $_REQUEST ); $gContent->loadTopic(); header( "Location: " . ARTICLES_PKG_URL . "admin/admin_topics.php" ); + die; } elseif( isset( $_REQUEST['fRemoveTopicImage'] ) ) { $gContent->removeTopicImage(); } @@ -17,7 +17,7 @@ $gBitSystem->verifyPermission( 'p_articles_read' ); if( !empty( $_REQUEST['article_id'] ) ) { $param = array ( 'article_id' => ( int )$_REQUEST['article_id'] ); header( "Location: ".BitArticle::getDisplayUrlFromHash( $param ) ); - exit; + die; } // Display the template |
