dsg
INSERT INTO `cp_filehtml` (`id`,`modul`,`app`,`path`,`type`,`cat`,`file_name`,`content`) VALUES ('387','profile','1','u2/creator','0','js','view-user-profile.js-','$(document).on(\\\'page:beforein\\\', \\\'.page[data-name=\\\"profile-view\\\"]\\\', async function (e) {\r\n $(\\\'.loading-fullscreen\\\').show()\r\n\r\n var pathStore = store.getters.getPathData\r\n userId = e.detail.route.params.id\r\n\r\n const sessionUser = await getSessionUser()\r\n\r\n if (!sessionUser || !sessionUser.id) {\r\n return;\r\n }\r\n\r\n // Follow button\r\n const followButton = $(\\\'.user-follow-btn\\\')\r\n const sessionFollowings = sessionUser.following;\r\n\r\n if (sessionFollowings.includes(`${userId}`)) {\r\n followButton.text(\\\'Following\\\')\r\n } else {\r\n followButton.text(\\\'Follow\\\')\r\n }\r\n\r\n followButton.attr(\\\'data-user-id\\\', userId)\r\n\r\n let cachedData = null\r\n try {\r\n if (pathStore && pathStore.value[`/user/${userId}`]) {\r\n cachedData = pathStore.value[`/user/${userId}`]\r\n }\r\n } catch (error) {\r\n console.error(\\\'Error fetching cached data:\\\', error)\r\n }\r\n\r\n await renderProfileData(cachedData, userId)\r\n})');
Copy This

Warning: file_get_contents(/home/u340524018/domains/agniaga.com/public_html/sub/u2/creator/view-user-profile.js-): Failed to open stream: No such file or directory in /home/u340524018/domains/agniaga.com/public_html/sub/u2/cp/inc.filehtml.php on line 319
$(document).on(\'page:beforein\', \'.page[data-name=\"profile-view\"]\', async function (e) {
    $(\'.loading-fullscreen\').show()

    var pathStore = store.getters.getPathData
    userId = e.detail.route.params.id

    const sessionUser = await getSessionUser()

    if (!sessionUser || !sessionUser.id) {
        return;
    }

    // Follow button
    const followButton = $(\'.user-follow-btn\')
    const sessionFollowings = sessionUser.following;

    if (sessionFollowings.includes(`${userId}`)) {
        followButton.text(\'Following\')
    } else {
        followButton.text(\'Follow\')
    }

    followButton.attr(\'data-user-id\', userId)

    let cachedData = null
    try {
        if (pathStore && pathStore.value[`/user/${userId}`]) {
            cachedData = pathStore.value[`/user/${userId}`]
        }
    } catch (error) {
        console.error(\'Error fetching cached data:\', error)
    }

    await renderProfileData(cachedData, userId)
})
Array
(
)
Add JS Function Name