ACIL FM
Dark
Refresh
Current DIR:
/home/mhhtmff/www/site/wp-content/plugins/wpml-string-translation/classes
/
home
mhhtmff
www
site
wp-content
plugins
wpml-string-translation
classes
Upload
Zip Selected
Delete Selected
Pilih semua
Nama
Ukuran
Permission
Aksi
actions
-
chmod
Open
Rename
Delete
admin-texts
-
chmod
Open
Rename
Delete
API
-
chmod
Open
Rename
Delete
basket
-
chmod
Open
Rename
Delete
batch-translation
-
chmod
Open
Rename
Delete
container
-
chmod
Open
Rename
Delete
db-mappers
-
chmod
Open
Rename
Delete
filters
-
chmod
Open
Rename
Delete
gettext-hooks
-
chmod
Open
Rename
Delete
menus
-
chmod
Open
Rename
Delete
MO
-
chmod
Open
Rename
Delete
package
-
chmod
Open
Rename
Delete
package-translation
-
chmod
Open
Rename
Delete
po-import
-
chmod
Open
Rename
Delete
privacy
-
chmod
Open
Rename
Delete
records
-
chmod
Open
Rename
Delete
shortcode
-
chmod
Open
Rename
Delete
slug-translation
-
chmod
Open
Rename
Delete
string-tracking
-
chmod
Open
Rename
Delete
string-translation
-
chmod
Open
Rename
Delete
string-translation-ui
-
chmod
Open
Rename
Delete
strings-cleanup
-
chmod
Open
Rename
Delete
strings-scanning
-
chmod
Open
Rename
Delete
support
-
chmod
Open
Rename
Delete
translation-files
-
chmod
Open
Rename
Delete
translation-memory
-
chmod
Open
Rename
Delete
translations-file-scan
-
chmod
Open
Rename
Delete
Troubleshooting
-
chmod
Open
Rename
Delete
upgrade
-
chmod
Open
Rename
Delete
utilities
-
chmod
Open
Rename
Delete
wpml-tm
-
chmod
Open
Rename
Delete
class-wpml-admin-notifier.php
270 B
chmod
View
DL
Edit
Rename
Delete
class-wpml-language-of-domain.php
986 B
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-admin-string.php
752 B
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-initialize.php
1.15 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-reset.php
1.58 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-settings.php
1.27 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-string-factory.php
2.93 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-string-statuses.php
808 B
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-string.php
9.1 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-strings.php
10.34 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-user-fields.php
5.33 MB
chmod
View
DL
Edit
Rename
Delete
class-wpml-st-verify-dependencies.php
1.12 MB
chmod
View
DL
Edit
Rename
Delete
Shortcode.php
2.06 MB
chmod
View
DL
Edit
Rename
Delete
TranslateWpmlString.php
5.43 MB
chmod
View
DL
Edit
Rename
Delete
Edit file: /home/mhhtmff/www/site/wp-content/plugins/wpml-string-translation/classes/Shortcode.php
<?php namespace WPML\ST; class Shortcode { const STRING_DOMAIN = 'wpml-shortcode'; private $context; private $name; /** * @var \wpdb */ private $wpdb; public function __construct( \wpdb $wpdb ) { $this->wpdb = $wpdb; } function init_hooks() { add_shortcode( 'wpml-string', [ $this, 'render' ] ); } /** * @param array $attributes * @param string $value * * @return string */ function render( $attributes, $value ) { $this->parse_attributes( $attributes, $value ); $this->maybe_register_string( $value ); return do_shortcode( icl_t( $this->context, $this->name, $value ) ); } /** * @param string $value */ private function maybe_register_string( $value ) { $string = $this->get_registered_string(); if ( ! $string || $string->value !== $value ) { icl_register_string( $this->context, $this->name, $value ); } } /** * @param array $attributes * @param string $value */ private function parse_attributes( $attributes, $value ) { $pairs = array( 'context' => self::STRING_DOMAIN, 'name' => 'wpml-shortcode-' . md5( $value ), ); $attributes = shortcode_atts( $pairs, $attributes ); $this->context = $attributes['context']; $this->name = $attributes['name']; } /** * @return \stdClass */ private function get_registered_string() { $strings = $this->get_strings_registered_in_context(); if ( $strings && array_key_exists( $this->name, $strings ) ) { return $strings[ $this->name ]; } return null; } /** * @return \stdClass[] */ private function get_strings_registered_in_context() { $cache_key = $this->context; $cache_group = 'wpml-string-shortcode'; $cache_found = false; $string = wp_cache_get( $cache_key, $cache_group, false, $cache_found ); if ( ! $cache_found ) { $query = 'SELECT name, id, value, status FROM ' . $this->wpdb->prefix . 'icl_strings WHERE context=%s'; $sql = $this->wpdb->prepare( $query, $this->context ); $string = $this->wpdb->get_results( $sql, OBJECT_K ); wp_cache_set( $cache_key, $string, $cache_group ); } return $string; } }
Simpan
Batal
Isi Zip:
Unzip
Create
Buat Folder
Buat File
Terminal / Execute
Run
Chmod Bulk
All File
All Folder
All File dan Folder
Apply