I am using the WP Plugin – CODE EMBED. I am using it for on page text and now trying to use it for images.
Specifically i will use the below image on the referenced page as an example of my issue. RE: The first image of woman standing in front of van at the top of the page.
I am trying to use the CODE EMBED plugin to rename images through alt text. I can do this but with one issue. When i use the {{CODECITY}} in alt text it adds a space before and after the word.
I want the image alt text to show as: sewer-scope-Denver-Colorado
But instead it shows up on inspection as: sewer-scope- Denver – Colorado
I am using this code:
sewer-scope-inspection-company-{{CODECITY}}-{{CODESTATE}}
HOw do I eliminate the spaces.
Do the spaces matter for SEO?
]]>I was able to install the plugin CodeEmbed successfully, however, when I go to CodeEmbed settings on the plugin page, I receive this message, “Sorry, you are not allowed to access this page.” Note that CodeEmbed settings are not available on the WordPress “Settings” menu. Is this a fatal error or can I fix it?
]]>With version 2.3.7, pages containing an embedded code do not load and time out.
I am using Code Embed to embed html from urls. For example, in Custom Fields:
Name: CODE:example-page
Value: %https://example.com/example-page.html%
And on the page:
%CODE:example-page%
My WordPress installation is up-to-date (6.4.1-en_GB), as is php (8.1.25).
Rolling back to version 2.3.6 of code embed solves the problem (so the page linked to above works).
]]>can;t see how to use this which is now installed. The page says to see FAQ for use with blocks, but FAQ does not exist.
]]>Can’t see how to use this with Blocks. The page says to see FAQ, which is not shown anywhere.
]]>Script working from plugin but only shows after footer not in body which is where it is added.
What am I missing?
]]>Hello. A former vendor installed Embed Code plugin so we could his service. We no longer use the service and I want to remove his code.
The script was entered in the Head Code Box under Global Code and does appear on every page. Every time I try to delete the code (select all, delete, save changes) the code reappears.
How do I delete the code from every page once and for all, other than to delete the plugin? What is preventing me from doing a simple delete? I don’t want to delete the plug, I just want this java script code gone.
Thanks for the help.
Dave LeBlanc
]]>Hello,
Is there a way to make an embed code work in pages generated by Woocommerce, such as the Shop page? I have an embed code that works on a WordPress page of my site, but the same code {{CODE-video-review-examples-good-vs-bad}} does not work on my site’s Shop page.
Best regards,
TK
]]>Hi,
Thanks for your greate plugin, it really helps to solve the embed problem for the social medias for classic editor user. There is only one thing which I hope can be improved in the future. When there are emojis in the embed code, they can’t be saved in the custom field, I have to manually remove the emojis then only it can be saved. Sample codes as below:
<blockquote class="tiktok-embed" cite="https://www.tiktok.com/@shuibsepahtu/video/7120892464201764122" data-video-id="7120892464201764122" style="max-width: 605px;min-width: 325px;" > <section> <a target="_blank" title="@shuibsepahtu" href="https://www.tiktok.com/@shuibsepahtu">@shuibsepahtu</a> Siakap sawah ???? <a title="pershuibofhappyness" target="_blank" href="https://www.tiktok.com/tag/pershuibofhappyness">#pershuibofhappyness</a> <a title="fyp" target="_blank" href="https://www.tiktok.com/tag/fyp">#Fyp</a> <a title="belut" target="_blank" href="https://www.tiktok.com/tag/belut">#Belut</a> <a target="_blank" title="? original sound - Shuib Sepahtu" href="https://www.tiktok.com/music/original-sound-Shuib-Sepahtu-7120892499144559386">? original sound - Shuib Sepahtu</a> </section> </blockquote> <script async src="https://www.tiktok.com/embed.js"></script>
Any method to solve this limitation?
Thanks.
]]>Hello,
in the beginning I want to notice that I am not programmer and with wordpress I am working just a week ?? We are making event sport result and i have script to integrate in page but this works only on computer where I am editing page (wordpress) and on other devices is show just spinning wheel. code for integration is for example:
<div id="divRRPublish" class="RRPublish"></div>
<script type="text/javascript" src="https://my.raceresult.com/RRPublish/load.js.php?lang=en"></script>
<script type="text/javascript">
<!--
var rrp=new RRPublish(document.getElementById("divRRPublish"), 210488, "results");
rrp.ShowTimerLogo=true;
rrp.ShowInfoText=false;
-->
</script>
I do not know what is wrong. Please help me how to do it correctly. Thank You
]]>Hi I have a problem where custom field don’t show. I’ve checked under “options” -> “preferences” and there is no custom field option there. I also changed my theme back to the classic editor and checked the “page options” tab and still don’t see the custom field option.
The theme I’m using seems very locked down and I think that might be the issue.
Any ideas?
]]>I am trying to embed a google site URL but when I do… the page or post forwards to the site rather than embedding. Please let me know what I should do to fix this either in the URL {{URL}} or as a CODE value.
]]>Hello. Just tried to install Code Embed plugin. Got error message: “Installation failed: Download failed. cURL error 7: Failed to connect to downloads.www.remarpro.com port 443: Connection timed out” Running WordPress 5.9.2 Any suggestions appreciated.
]]>I want to add the code snippet to the main posts page so that it is executed there, not within each post.
I do not see any content which I can add to on there.
The code snippet does execute within the posts as I can add {{CODE1}} and it works.
Any help would be geat.
]]>Hello,
I get this error:
Code Embed: Cannot use CODE6 as a global code as it is being used to store 2 unique pieces of code in 5 posts
What can we do?
]]>Hi, firstly thank you for creating ‘code embed’ for us to embed our source code into the website. But i have a question, if I want to add a source code into my webpage on wordpress. How to link? I have watched youtube tutorials but that video was 8 years ago and outdated. Do u have a step by step guide on how to link a source code into ‘Code Embed’ to add to our website? thanks!
]]>hello,
Loving this plug-in but I have hit a snag with three.js + Physi.js. In short, I cannot get Physi.js to work – nothing shows up on the page in which it is embedded. I have tested some of Three.js and some other helper libraries and they work fine with Code Embed. Below is the code that I have been using – the simplest scene possible consisting of just a single cube. There are a couple of commented out lines that I was experimenting with – I am just learning three.js. I absolutely need some physics and from what I have seen so far physi.js seems like the best.
<script type=”text/javascript” charset=”UTF-8″ src=”../libs/three/build/three.js”></script>
<script type=”text/javascript” charset=”UTF-8″ src=”../libs/other/physijs/physi.js”></script>
<script>
Physijs.scripts.worker = ‘../libs/other/physijs/physijs_worker.js’;
Physijs.scripts.ammo = ‘../libs/other/physijs/ammo.js’;
var scene = new Physijs.Scene;
var camera = new THREE.PerspectiveCamera(45, window.innerWidth / window.innerHeight, 0.1, 1000);
var renderer = new THREE.WebGLRenderer();
renderer.setClearColor(new THREE.Color(0x000000));
renderer.setSize(window.innerWidth, window.innerHeight);
document.body.appendChild(renderer.domElement);
var cube = new Physijs.BoxMesh(new THREE.BoxGeometry(4, 4, 4),
Physijs.createMaterial(new THREE.MeshStandardMaterial({color: 0x0000ff}), 0.4, 0.4));
cube.castShadow = true;
cube.position.x = -4;
cube.position.y = 2;
cube.position.z = 0;
scene.add(cube);
camera.position.x = -30;
camera.position.y = 40;
camera.position.z = 30;
camera.lookAt(scene.position);
var spotLight = new THREE.SpotLight(0xFFFFFF);
spotLight.position.set(-40, 40, -15);
spotLight.castShadow = true;
spotLight.shadow.mapSize = new THREE.Vector2(1024, 1024);
spotLight.shadow.camera.far = 130;
spotLight.shadow.camera.near = 40;
scene.add(spotLight);
var ambientLight = new THREE.AmbientLight(0x353535);
scene.add(ambientLight);
//document.body.appendChild(renderer.domElement);
scene.simulate();
//requestAnimationFrame(render);
render();
function render() {
requestAnimationFrame(render);
renderer.render(scene, camera);
scene.simulate(undefined, 1);
}
</script>`
Thank you for this excellent plug-in!
]]>Hi,
I have installed the plugin. Created the custom field and included the code on the page but it is not displayed. In the source code if the script appears but is not displayed on the front end. I use Avada theme. Thank you
On my site I have been using your plugin (Code Embed) very much with a success.
Recently however, due to the process of creating a new template I had to install an Advanced Custom Fields plugin. It seems to be in conflict with Code Embed in a way that it is no longer showing Code Embed Metabox in Page Editor. The issue is critical as I am actively using {{CODE}} embbeds and can’t edit those fields.
I am using Classic Editor 1.6.2, WordPress 5.7.2, PHP 7.3.10, Code Embed 2.3.4, ACF 5.11.3.
What can I do to manage the situation?
]]>I’m trying to add the code to this guide; https://github.com/ethanaobrien/emulatorjs
But I can’t do it. I’ve tried everything, including your plugin. I’m sure I’m doing something wrong, being a beginner and no knowledge of JS.
Also, I don’t quite understand where to copy the {{CODEmyjscode}} code after adding the script in preferences.
]]>Hello — one of my admins has placed this plugin on our site.
One admin says he has not installed it, the other two do not know anymore (lol)
Now I am uncertain what the plugin does for our site. so how can we easily see on which page the code embed plugin was used to add code?
Thank you
]]>If you’re using a third-party site builder then, chances are, it won’t work with this plugin. This is because the plugin expects your code request to be inside the standard editor.
The only way around this would be for this plugin to also look at whatever these third party plugins are using as well – there are so many, none of which I personally use, that this would be a massive undertaking.
However, if any developers want to approach me and request compatibility then I would be happy to add it… if they tell me what hooks to use.
If you’re a user then you can ask your favourite site builder to get in touch.
]]>So after typing in the CODEname then added the javascript code, it won’t allow me to update if the </scritpt> tag is included in the code. IF I don’t add the tag it displays the string on the page instead of doing what the code is supposed to do. Any way to fx this?
]]>Hello, i discovered the embed code, and it was i needed, but having som issues with miffin builder. I just do the steps on faq with defalut code1. if i past on the code on classical editor it works, but if i paste it on any block nothing happends and shows just {{CODE1}}. Any sugestion here?
]]>I’m using your plugin to replace code that was previously embedded with a now obsolete plugin named EmbedIt (SuperPro).
The site has used the obsolete plugin to embed hundreds of videos into about 100 posts. I’m aware that your plugin does not permit reuse of custom field names because your custom field names are assigned globally on the site, not per post.
I’d like to know before I go too far down this path whether I’ll hit a wall of maximum custom field names.
]]>Hi,
Is there any workaround to get this to work on category pages? Long shot posting here I know, but maybe another user has found a solution, and can help me out. Or maybe it’s obvious and I’m just stupid haha, that wouldn’t surprise me ??
I’ve read the topic explaining why shortcodes can’t be used, and as far as I can tell, there isn’t a plugin that allows for displaying the ‘add new custom field’ when trying to edit category pages.
I use a plugin ‘Category Editor’ that adds a tinymce, so I can treat a category almost like a ‘post’ or ‘page’, but it doesn’t allow the ability for that add custom field entry, and putting {{CODExyz}} to pull from a working instance within another post on the site also doesn’t work – I assume because it isn’t a shortcode, and ofc can’t be a shortcode because that strips the output (as I’m finding when I have tried a few other plugins that allegedly allow for javascript to be inserted).
Not sure if I’ve explained all that very well, if not I can clarify whatever is needed.
Thanks, and just to say nice plugin; I’ve been using it on posts & pages no problem, just the categories I can’t yet get it to work on.
]]>Code Embed is wonderful to the point of seeming like magic. And so simple to use. I have one bit of a bug, however. I have a Guess My Number game to go with a blog post. It show up and works exactly as expected on both Mac and Windows, but does not show up—and greatly extends the window—on iOS/iPadOS.
I have included the code. Is there anything you can see that does not play nicely with iOS/iPadOS, something I should leave out or add? It is vanilla HTML/CSS/JS.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Number Guessing</title>
<style>
.lastResult {
color: black;
padding: 7px;
}
.guesses {
color: #000000;
padding: 4px;
}
button {
background-color: #fbfaf6;
color: #fbfaf6;
width: 144px;
height: 36px;
border-radius: .25em;
font-size: 18px;
border-style: none;
}
#subt {
background-color: #00ff0d;
color: #000;
width: 200px;
height: 48px;
border-radius: .75em;
font-size: 16px;
border-style: solid;
margin-top: 24px;
}
#guessField {
color: #000;
width: 200px;
height: 48px;
font-size: 24px;
border-style: none;
margin-top: 24px;
border: 5px solid #a1abc8;
text-align: center;
}
#guess {
font-size: 18px;
margin-top: 20px;
color: #263048;
}
#wrapper {
width: 400px;
height: 440px;
text-align: center;
font-size: 24px;
color: #000000;
background-color: #fbfaf6;
box-sizing: border-box;
border:0;
overflow: hidden;
margin: 0 auto;
display:block;
}
</style>
</head>
<body>
<div id="wrapper">
<form class="form">
<label2 for="guessField" id="guess">Guess My Number 1 to 100</label>
<br>
<input type="text" id="guessField" class="guessField">
<br>
<input type="submit" id="subt" value="Submit Guess" class="guessSubmit"> </form>
<div class="resultParas">
<br>
<p>Numbers Tried: <span class="guesses"></span></p>
<p>Tries Remaining: <span class="lastResult">7</span></p>
<p class="lowOrHi"></p>
</div>
</div>
<script>
// Generate a random number from 1 to 100
let randomNumber = parseInt((Math.random() * 100) + 1);
const submit = document.querySelector('#subt');
const userInput = document.querySelector('#guessField');
const guessSlot = document.querySelector('.guesses');
const remaining = document.querySelector('.lastResult');
const startOver = document.querySelector('.resultParas');
const lowOrHi = document.querySelector('.lowOrHi');
const p = document.createElement('p');
let previousGuesses = [];
let numGuesses = 1;
let playGame = true;
if(playGame) {
subt.addEventListener('click', function(e) {
e.preventDefault();
//Grab guess from user
const guess = parseInt(userInput.value);
validateGuess(guess);
});
}
function validateGuess(guess) {
if(isNaN(guess)) {
alert('enter a valid number');
} else if(guess < 1) {
alert('enter a number, 1 or more');
} else if(guess > 100) {
alert('enter a number, 100 or less')
} else {
//Keep record of number of attempted guesses
previousGuesses.push(guess);
//Check to see if game is over
if(numGuesses === 8) {
displayGuesses(guess);
displayMessage(<code>Game Over. My number was ${randomNumber}</code>);
endGame();
} else {
//Display previous guessed numbers
displayGuesses(guess);
//Check guess and display if wrong
checkGuess(guess);
}
}
}
function checkGuess(guess) {
// Display clue if guess is too high or too low
if(guess === randomNumber) {
displayMessage(<code>CORRECT</code>);
endGame();
} else if(guess < randomNumber) {
displayMessage(<code>Too low. Try again.</code>);
} else if(guess > randomNumber) {
displayMessage(<code>Too High. Try again.</code>);
}
}
function displayGuesses(guess) {
userInput.value = '';
guessSlot.innerHTML += <code>${guess}</code>;
numGuesses++
remaining.innerHTML = <code>${8 - numGuesses}</code>;
}
function displayMessage(message) {
lowOrHi.innerHTML = <code><h6>${message}</h6></code>
}
function endGame() {
// Clear user input
userInput.value = '';
// Disable user input button
userInput.setAttribute('disabled', '');
// Display Start new Game Button
p.classList.add('button');
p.innerHTML = <code><h6 id="newGame">Start New Game</h6></code>
startOver.appendChild(p);
playGame = false;
newGame();
}
function newGame() {
const newGameButton = document.querySelector('#newGame');
newGameButton.addEventListener('click', function() {
// Pick a new random number
randomNumber = parseInt((Math.random() * 100) + 1);
previousGuesses = [];
numGuesses = 1;
guessSlot.innerHTML = '';
lowOrHi.innerHTML = '';
remaining.innerHTML = <code>${11 - numGuesses}</code>;
userInput.removeAttribute('disabled');
startOver.removeChild(p);
playGame = true;
})
}
</script>
</body>
</html>
]]>
Hi there – some time ago y0ou mentioned you were working on a shortcode embed option.
This would open it up for use in many page builders (currently not working in Enfold for example).
Did anything come of this?
Thanks.
]]>Hi,
Its a great tool! Thank you! I have a unique request.
Imagine CODE1 is for a certain code
Code2 for a certain code to run
Code3 etc etc
and you want the page to run ONLY with one of the above at one time.
+
You want them to run on a click (like a hyperlink), + my guess the page might need to refresh to execute. so it would be something like
Click Google1 -> Google.com/Code1.html
Click Google2 -> Google.com/Code2.html
Any way to do this, or am I forced to make seperate pages?
Thanks@ T
Good morning
I installed Code Embed on the site I’m building and I have a problem that I can’t understand. I’m working in parallel on an online version and a local version. I easily created my custom CODEnovela field and entered the value in the Value field. This java code corresponds to an affiliation with a company.
I work with WordPress 5.6.2 and the OceanWP theme.
The same extensions are installed on both versions of the site.
The only difference between the two versions of the site is that the local is in HTTP and the one online in HTTPS.
The java script works perfectly on the local site, and on the online site it does not appear.
When I look at the source code of the 2 pages, the java code is perfectly identical on the 2 pages.
No matter how hard I look, I don’t understand what the problem is. Do you have any idea where this problem might come from?
Thank you for your help. Kind regards.