> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aftersell.com/llms.txt
> Use this file to discover all available pages before exploring further.

# رأس الموقع يتداخل مع Upcart

> يشرح هذا المقال كيفية إصلاح مشكلة اختفاء أداة Upcart خلف رأس موقعك عند فتحها.

<div id="why-this-happens">
  ### لماذا يحدث هذا
</div>

في بعض قوالب Shopify، يكون للرأس قيمة **z-index** أعلى من Upcart، مما يجعل السلة تظهر تحته. قد يؤدي هذا إلى ظهور Upcart مخفيًا جزئيًا أو غير قابل للوصول عندما يفتح العملاء السلة.

***

<div id="how-to-fix">
  ## كيفية الإصلاح
</div>

اتبع الخطوات أدناه لجعل Upcart يظهر أمام رأس موقعك:

1. **انسخ الكود** المتوفر في أسفل هذا المقال.
2. في لوحة تحكم Shopify، افتح **Cart Editor** الخاص بـ Upcart، وانتقل إلى **Settings**، واختر تبويب **Custom HTML**. Settings عبارة عن صف من التبويبات — إذا لم ترَ Custom HTML، فستجده خلف **More settings**.
3. انقر على **القائمة المنسدلة HTML** واختر **Scripts (Before Load)**.
4. **الصق الكود** في الحقل.
5. انقر على **Save changes**.
6. **حدّث واجهة متجرك** واختبر سلتك.

بعد إتمام هذه الخطوات، ينبغي أن تُعرض السلة بشكل صحيح فوق رأس موقعك.

***

<div id="code-required">
  ## الكود المطلوب:
</div>

```
<script>  
	// Find UpCart  
	let upcart = document.querySelector("#upCart");  
  
	// Find the site's body  
	let body = document.body;  
	  
	// If we found both  
	if(upcart && body)  
			// Move upcart to the top of the body's children so it takes priority over site header  
	    body.firstChild.before(upcart)  
</script>
```
