AI Search
Classic Search
 Search Phrase:
 Search Type:
Advanced search options
 Search in Forums:
 Search in date period:

 Sort Search Results by:

AI Assistant
Notifications
Clear all

[Closed] users are not able to edit their profile

8 Posts
2 Users
0 Reactions
4,928 Views
Robert
Posts: 10753
Admin
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@robert)
Support Team
Joined: 3 months ago
Posted by: emanuelusa

Parse error: syntax error, unexpected 'function' (T_FUNCTION) in /home/volitud8/public_html/wp-content/themes/dt-the7/functions.php on line 3

You put it in other function or in other code, please be attentive. Put it a at the end of functions.php, make sure there is nothing after this code. Don't put it on beginning of your file, I see line 3.


Posts: 11
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@emanuelusa)
Active Member
Joined: 9 years ago

Hi there, here is the code that I am making, and I am still getting the error message

<?php

 

/**

 

 * Vogue theme.

 

 *

 

 * @since 1.0.0

 

 */

 

 

 

// File Security Check

 

if ( ! defined( 'ABSPATH' ) ) { exit; }

 

 

 

/**

 

 * Set the content width based on the theme's design and stylesheet.

 

 *

 

 * @since 1.0.0

 

 */

 

if ( ! isset( $content_width ) ) {

 

$content_width = 1200; /* pixels */

 

}

 

 

 

/**

 

 * Initialize theme.

 

 *

 

 * @since 1.0.0

 

 */

 

require( trailingslashit( get_template_directory() ) . 'inc/init.php' );

 

function wpforo_custom_profile_url( $url, $userid, $scheme ) {

    if(!is_admin()){

        global $wpforo;

        return $wpforo->member->get_profile_url($userid);

    }

    else{

        return $url;

    }

}

add_filter( 'edit_profile_url', 'wpforo_custom_profile_url', 10, 3 );


Robert
Posts: 10753
Admin
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@robert)
Support Team
Joined: 3 months ago

Please put it after this code, make sure you've removed it from other places before put it again:

if ( ! defined( 'ABSPATH' ) ) { exit; }

Page 2 / 2
Share: